feat: update
This commit is contained in:
@@ -73,17 +73,17 @@ func test_option_values_match_schema():
|
||||
var expected_type = schema[option]["type"]
|
||||
|
||||
if expected_type == "bool":
|
||||
assert_is(value, bool, "Option '%s' should be bool" % option)
|
||||
assert_true(value is bool, "Option '%s' should be bool" % option)
|
||||
|
||||
# Test 6: Game modes are defined
|
||||
func test_game_modes_defined():
|
||||
var modes = mode_config.get("game_modes", [])
|
||||
assert_is_not_empty(modes, "Game modes should be defined")
|
||||
assert_false(modes.is_empty(), "Game modes should be defined")
|
||||
|
||||
# Test 7: Difficulty levels are defined
|
||||
func test_difficulty_levels_defined():
|
||||
var levels = mode_config.get("difficulty_levels", [])
|
||||
assert_is_not_empty(levels, "Difficulty levels should be defined")
|
||||
assert_false(levels.is_empty(), "Difficulty levels should be defined")
|
||||
|
||||
# Test 8: No inconsistent option values
|
||||
func test_no_inconsistent_values():
|
||||
@@ -94,7 +94,7 @@ func test_no_inconsistent_values():
|
||||
var value = options[option]
|
||||
var default = schema[option]["default"]
|
||||
# Value should be same type as default
|
||||
assert_is(value, typeof(default), "Option '%s' type mismatch" % option)
|
||||
assert_eq(typeof(value), typeof(default), "Option '%s' type mismatch" % option)
|
||||
|
||||
# Test 9: Config can be validated against schema
|
||||
func test_config_validates_against_schema():
|
||||
|
||||
Reference in New Issue
Block a user