mirror of
https://github.com/godotengine/godot-cpp.git
synced 2026-01-06 06:10:06 +03:00
Add automated tests that run a GDExtension (rather than just building it)
This commit is contained in:
24
test/run-tests.sh
Executable file
24
test/run-tests.sh
Executable file
@@ -0,0 +1,24 @@
|
||||
#!/bin/bash
|
||||
|
||||
GODOT=${GODOT:-godot}
|
||||
|
||||
END_STRING="==== TESTS FINISHED ===="
|
||||
FAILURE_STRING="******** FAILED ********"
|
||||
|
||||
OUTPUT=$($GODOT --path project --debug --headless --quit)
|
||||
ERRCODE=$?
|
||||
|
||||
echo "$OUTPUT"
|
||||
echo
|
||||
|
||||
if ! echo "$OUTPUT" | grep -e "$END_STRING" >/dev/null; then
|
||||
echo "ERROR: Tests failed to complete"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if echo "$OUTPUT" | grep -e "$FAILURE_STRING" >/dev/null; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Success!
|
||||
exit 0
|
||||
Reference in New Issue
Block a user