1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-13 16:13:34 +08:00

Fix test crosstalk

This commit is contained in:
Bartłomiej Dach 2024-03-15 09:46:18 +01:00
parent 4688a53cf4
commit 4e2098adb8
No known key found for this signature in database

View File

@ -37,8 +37,8 @@ namespace osu.Game.Tests.Visual.Gameplay
private TestPlayerLoader loader;
private TestPlayer player;
private bool epilepsyWarning;
private BeatmapOnlineStatus onlineStatus;
private bool? epilepsyWarning;
private BeatmapOnlineStatus? onlineStatus;
[Resolved]
private AudioManager audioManager { get; set; }
@ -83,7 +83,12 @@ namespace osu.Game.Tests.Visual.Gameplay
}
[SetUp]
public void Setup() => Schedule(() => player = null);
public void Setup() => Schedule(() =>
{
player = null;
epilepsyWarning = null;
onlineStatus = null;
});
[SetUpSteps]
public override void SetUpSteps()
@ -121,8 +126,8 @@ namespace osu.Game.Tests.Visual.Gameplay
workingBeatmap.BeatmapInfo.AudioLeadIn = 60000;
// Set up data for testing disclaimer display.
workingBeatmap.BeatmapInfo.EpilepsyWarning = epilepsyWarning;
workingBeatmap.BeatmapInfo.Status = onlineStatus;
workingBeatmap.BeatmapInfo.EpilepsyWarning = epilepsyWarning ?? false;
workingBeatmap.BeatmapInfo.Status = onlineStatus ?? BeatmapOnlineStatus.Ranked;
Beatmap.Value = workingBeatmap;