mirror of
https://github.com/jcreek/CosmicClash.git
synced 2026-09-13 20:52:03 +00:00
feat(multiplayer): show authoritative proposal countdown
This commit is contained in:
@@ -17,3 +17,9 @@ func test_terminal_state_policy_does_not_leave_cancel_or_proposal_actions_enable
|
||||
assert_true(Matchmaking._can_start_new_search(MatchmakingState.FAILED), "failed search can be retried")
|
||||
assert_true(not Matchmaking._can_start_new_search(MatchmakingState.LIVE), "live match cannot start a second search")
|
||||
assert_true(Matchmaking._can_start_new_search(MatchmakingState.COMPLETED), "completed match can start a new search")
|
||||
|
||||
|
||||
func test_proposal_countdown_uses_authoritative_expiry_and_clamps_after_expiry() -> void:
|
||||
assert_eq(Matchmaking.proposal_countdown_text(1100, 1000), "Review proposal · 100s remaining", "proposal countdown uses server expiry")
|
||||
assert_eq(Matchmaking.proposal_countdown_text(1000, 1001), "Review proposal · 0s remaining", "expired proposal countdown clamps to zero")
|
||||
assert_eq(Matchmaking.proposal_countdown_text(0, 1000), "Review the proposal before the countdown expires", "missing expiry retains compatible copy")
|
||||
|
||||
Reference in New Issue
Block a user