test: Style cleanup after opening in 3.4

pull/648/head
Rémi Verschelde 2021-11-04 15:37:57 +01:00
parent 1070a29d77
commit c12e9a3195
No known key found for this signature in database
GPG Key ID: C3336907360768E1
2 changed files with 25 additions and 27 deletions

View File

@ -10,10 +10,8 @@ config_version=4
_global_script_classes=[ ] _global_script_classes=[ ]
_global_script_class_icons={ _global_script_class_icons={
} }
[application] [application]
config/name="Test CI project" config/name="Test CI project"

View File

@ -1,30 +1,30 @@
extends MainLoop extends MainLoop
func _initialize(): func _initialize():
OS.exit_code = 1 OS.exit_code = 1
var native_script = load("res://gdexample.gdns") var native_script = load("res://gdexample.gdns")
print("Native Script ", native_script) print("Native Script ", native_script)
if native_script == null || !is_instance_valid(native_script): if not native_script || !is_instance_valid(native_script):
return return
print("Library ", native_script.library) print("Library ", native_script.library)
if native_script.library == null || !is_instance_valid(native_script.library): if not native_script.library || !is_instance_valid(native_script.library):
return return
var ref = native_script.new() var ref = native_script.new()
print("Reference ", ref) print("Reference ", ref)
if ref == null || !is_instance_valid(ref): if not ref || !is_instance_valid(ref):
return return
print("Reference name ", ref.name) print("Reference name ", ref.name)
if ref.name != "SimpleClass": if ref.name != "SimpleClass":
return return
print("Reference value ", ref.value) print("Reference value ", ref.value)
if ref.value != 0: if ref.value != 0:
return return
print("Call method ", ref.method(1)) print("Call method ", ref.method(1))
if ref.method(1) != 1: if ref.method(1) != 1:
return return
OS.exit_code = 0 OS.exit_code = 0
func _idle(_delta): func _idle(_delta):
return true return true