Adding log.gd
This commit is contained in:
parent
eb32d6614e
commit
4522259397
547 changed files with 46844 additions and 0 deletions
43
addons/gdUnit4/test/mocker/GodotClassNameFuzzer.gd
Normal file
43
addons/gdUnit4/test/mocker/GodotClassNameFuzzer.gd
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
# fuzzer to get available godot class names
|
||||
class_name GodotClassNameFuzzer
|
||||
extends Fuzzer
|
||||
|
||||
var class_names := []
|
||||
const EXCLUDED_CLASSES = [
|
||||
"JavaClass",
|
||||
"_ClassDB",
|
||||
"MainLoop",
|
||||
"JNISingleton",
|
||||
"SceneTree",
|
||||
"WebRTC",
|
||||
"WebRTCPeerConnection",
|
||||
"Tween",
|
||||
"TextServerAdvanced",
|
||||
"InputEventShortcut",
|
||||
# GD-110 - missing enum `Vector3.Axis`
|
||||
"Sprite3D", "AnimatedSprite3D",
|
||||
]
|
||||
|
||||
|
||||
func _init(no_singleton :bool = false,only_instancialbe :bool = false):
|
||||
#class_names = ClassDB.get_class_list()
|
||||
for clazz_name in ClassDB.get_class_list():
|
||||
#https://github.com/godotengine/godot/issues/67643
|
||||
if clazz_name.contains("Extension"):
|
||||
continue
|
||||
if no_singleton and Engine.has_singleton(clazz_name):
|
||||
continue
|
||||
if only_instancialbe and not ClassDB.can_instantiate(clazz_name):
|
||||
continue
|
||||
# exclude special classes
|
||||
if EXCLUDED_CLASSES.has(clazz_name):
|
||||
continue
|
||||
# exlude Godot 3.5 *Tweener classes where produces and error
|
||||
# `ERROR: Can't create empty IntervalTweener. Use get_tree().tween_property() or tween_property() instead.`
|
||||
if clazz_name.find("Tweener") != -1:
|
||||
continue
|
||||
class_names.push_back(clazz_name)
|
||||
|
||||
|
||||
func next_value():
|
||||
return class_names[randi() % class_names.size()]
|
||||
Loading…
Add table
Add a link
Reference in a new issue