Also configure GUT to not treat push_error() as a test failure (client/.gutconfig.json: failure_error_types = [engine, gut]). The brief's LogPlayer/Quest setters intentionally push_error() on rejected input; GUT's default failure_error_types includes push_error, which would fail test_player_rejects_unknown_class and test_quest_status_enum despite their assertions passing. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
10 lines
251 B
GDScript
10 lines
251 B
GDScript
class_name Ids
|
|
extends RefCounted
|
|
## Shared id validation. Every canon-log / content id matches ^[a-z0-9_]+$.
|
|
|
|
static var _re: RegEx = RegEx.create_from_string("^[a-z0-9_]+$")
|
|
|
|
|
|
static func is_valid(id: String) -> bool:
|
|
return _re.search(id) != null
|