feat(client): Version helper + sync-version script; project.godot config/version
- Add scripts/sync-version to sync root /VERSION into client/project.godot - Add Version GDScript helper (reads application/config/version) - Test coverage: 2 tests for Version.string() and footer() - Synced config/version="0.01-alpha" to project.godot Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
13
client/tests/unit/test_version.gd
Normal file
13
client/tests/unit/test_version.gd
Normal file
@@ -0,0 +1,13 @@
|
||||
extends "res://addons/gut/test.gd"
|
||||
|
||||
|
||||
func test_string_matches_project_setting():
|
||||
var expected := str(ProjectSettings.get_setting("application/config/version", ""))
|
||||
assert_ne(expected, "", "project.godot must carry application/config/version (run scripts/sync-version)")
|
||||
assert_eq(Version.new().string(), expected)
|
||||
|
||||
|
||||
func test_footer_contains_version_and_engine():
|
||||
var v := Version.new()
|
||||
assert_string_contains(v.footer(), v.string())
|
||||
assert_string_contains(v.footer(), "BUILT IN GODOT 4.7")
|
||||
Reference in New Issue
Block a user