mirror of
https://github.com/godotengine/godot.git
synced 2025-10-31 21:51:22 +00:00
Fix error on parsing statement-less GDScript files,
add an empty file warning, add relevant tests.
This commit is contained in:
parent
bb0122c933
commit
e99730340b
13 changed files with 57 additions and 4 deletions
|
|
@ -496,7 +496,10 @@ GDScriptTest::TestResult GDScriptTest::execute_test_code(bool p_is_generating) {
|
|||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
// Script files matching this pattern are allowed to not contain a test() function.
|
||||
if (source_file.match("*.notest.gd")) {
|
||||
return result;
|
||||
}
|
||||
// Test running.
|
||||
const Map<StringName, GDScriptFunction *>::Element *test_function_element = script->get_member_functions().find(GDScriptTestRunner::test_function_name);
|
||||
if (test_function_element == nullptr) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue