summaryrefslogtreecommitdiffstats
path: root/modules/gdscript/tests/scripts/parser/features/variable_declaration.gd
diff options
context:
space:
mode:
authorAndrii Doroshenko (Xrayez) <xrayez@gmail.com>2021-04-16 22:16:19 +0300
committerAndrii Doroshenko (Xrayez) <xrayez@gmail.com>2021-04-16 22:16:19 +0300
commit1e26bf23c22b2e425be3ee1b00326a0af129337f (patch)
tree22fa02e58c8d8e9e7aae6ce2841f552c3a6f3c3f /modules/gdscript/tests/scripts/parser/features/variable_declaration.gd
parent49511d439124ab5a71defd22639737f45bd0ff70 (diff)
downloadredot-engine-1e26bf23c22b2e425be3ee1b00326a0af129337f.tar.gz
Rename GDScript test script filenames to use `snake_case`
Diffstat (limited to 'modules/gdscript/tests/scripts/parser/features/variable_declaration.gd')
-rw-r--r--modules/gdscript/tests/scripts/parser/features/variable_declaration.gd12
1 files changed, 12 insertions, 0 deletions
diff --git a/modules/gdscript/tests/scripts/parser/features/variable_declaration.gd b/modules/gdscript/tests/scripts/parser/features/variable_declaration.gd
new file mode 100644
index 0000000000..3b48f10ca7
--- /dev/null
+++ b/modules/gdscript/tests/scripts/parser/features/variable_declaration.gd
@@ -0,0 +1,12 @@
+var a # No init.
+var b = 42 # Init.
+
+func test():
+ var c # No init, local.
+ var d = 23 # Init, local.
+
+ a = 1
+ c = 2
+
+ prints(a, b, c, d)
+ print("OK")