diff options
| author | Dmitrii Maganov <vonagam@gmail.com> | 2023-03-08 22:06:29 +0200 |
|---|---|---|
| committer | Dmitrii Maganov <vonagam@gmail.com> | 2023-03-13 01:40:13 +0200 |
| commit | 4e34cf238aeff209f5823685d7b66ae8d66118cb (patch) | |
| tree | f1baec0d9450fc2c550f2a8ad9c9a8012802d9d6 /modules/gdscript/tests/scripts | |
| parent | 550a7798510810d238b733a54f69da71b2a2d152 (diff) | |
| download | redot-engine-4e34cf238aeff209f5823685d7b66ae8d66118cb.tar.gz | |
GDScript: Change parser representation of class extends
Diffstat (limited to 'modules/gdscript/tests/scripts')
4 files changed, 17 insertions, 0 deletions
diff --git a/modules/gdscript/tests/scripts/analyzer/errors/extend_non_gdscript_nested.gd b/modules/gdscript/tests/scripts/analyzer/errors/extend_non_gdscript_nested.gd new file mode 100644 index 0000000000..54cf4d89ec --- /dev/null +++ b/modules/gdscript/tests/scripts/analyzer/errors/extend_non_gdscript_nested.gd @@ -0,0 +1,5 @@ +class Foo extends RefCounted.Bar: + pass + +func test(): + print('not ok') diff --git a/modules/gdscript/tests/scripts/analyzer/errors/extend_non_gdscript_nested.out b/modules/gdscript/tests/scripts/analyzer/errors/extend_non_gdscript_nested.out new file mode 100644 index 0000000000..386d6261c6 --- /dev/null +++ b/modules/gdscript/tests/scripts/analyzer/errors/extend_non_gdscript_nested.out @@ -0,0 +1,2 @@ +GDTEST_ANALYZER_ERROR +Cannot get nested types for extension from non-GDScript type "RefCounted". diff --git a/modules/gdscript/tests/scripts/analyzer/errors/extend_unknown.gd b/modules/gdscript/tests/scripts/analyzer/errors/extend_unknown.gd new file mode 100644 index 0000000000..0f7d584edb --- /dev/null +++ b/modules/gdscript/tests/scripts/analyzer/errors/extend_unknown.gd @@ -0,0 +1,8 @@ +class Foo: + pass + +class Bar extends Foo.Baz: + pass + +func test(): + print('not ok') diff --git a/modules/gdscript/tests/scripts/analyzer/errors/extend_unknown.out b/modules/gdscript/tests/scripts/analyzer/errors/extend_unknown.out new file mode 100644 index 0000000000..42873056f2 --- /dev/null +++ b/modules/gdscript/tests/scripts/analyzer/errors/extend_unknown.out @@ -0,0 +1,2 @@ +GDTEST_ANALYZER_ERROR +Could not find nested type "Baz". |
