1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 14:17:26 +08:00

Add extra test coverage for marking score as failed

This commit is contained in:
Bartłomiej Dach 2023-10-27 11:58:02 +02:00
parent 86a8ab6db6
commit 3944b045ed
No known key found for this signature in database

View File

@ -247,6 +247,7 @@ namespace osu.Game.Tests.Visual.Navigation
AddStep("end spectator before retry", () => Game.SpectatorClient.EndPlaying(player.GameplayState)); AddStep("end spectator before retry", () => Game.SpectatorClient.EndPlaying(player.GameplayState));
AddStep("attempt to retry", () => player.ChildrenOfType<HotkeyRetryOverlay>().First().Action()); AddStep("attempt to retry", () => player.ChildrenOfType<HotkeyRetryOverlay>().First().Action());
AddAssert("old player score marked failed", () => player.Score.ScoreInfo.Rank, () => Is.EqualTo(ScoreRank.F));
AddUntilStep("wait for old player gone", () => Game.ScreenStack.CurrentScreen != player); AddUntilStep("wait for old player gone", () => Game.ScreenStack.CurrentScreen != player);
AddUntilStep("get new player", () => (player = Game.ScreenStack.CurrentScreen as Player) != null); AddUntilStep("get new player", () => (player = Game.ScreenStack.CurrentScreen as Player) != null);