Skip to content

Commit

Permalink
Merge pull request #52643 from ThreeRhinosInAnElephantCostume/fixgdsc…
Browse files Browse the repository at this point in the history
…ript

Fix an undefined behaviour causing random test failures
  • Loading branch information
mhilbrunner authored Sep 13, 2021
2 parents ad9717b + 2c71134 commit 7cdd862
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions modules/gdscript/tests/gdscript_test_runner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,7 @@ GDScriptTest::TestResult GDScriptTest::execute_test_code(bool p_is_generating) {
TestResult result;
result.status = GDTEST_OK;
result.output = String();
result.passed = false;

Error err = OK;

Expand Down Expand Up @@ -498,6 +499,8 @@ GDScriptTest::TestResult GDScriptTest::execute_test_code(bool p_is_generating) {
}
// Script files matching this pattern are allowed to not contain a test() function.
if (source_file.match("*.notest.gd")) {
enable_stdout();
result.passed = check_output(result.output);
return result;
}
// Test running.
Expand Down

0 comments on commit 7cdd862

Please sign in to comment.