1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 07:33:20 +08:00

Add failing test case

This commit is contained in:
Salman Ahmed 2023-06-15 11:05:06 +03:00
parent cabb4dfaa8
commit b9543f4fdd

View File

@ -453,6 +453,25 @@ namespace osu.Game.Tests.Visual.SongSelect
AddStep("Un-filter", () => carousel.Filter(new FilterCriteria(), false));
}
[Test]
public void TestRewindToDeletedBeatmap()
{
loadBeatmaps();
var firstAdded = TestResources.CreateTestBeatmapSetInfo();
AddStep("add new set", () => carousel.UpdateBeatmapSet(firstAdded));
AddStep("select set", () => carousel.SelectBeatmap(firstAdded.Beatmaps.First()));
nextRandom();
AddStep("delete set", () => carousel.RemoveBeatmapSet(firstAdded));
prevRandom();
AddAssert("deleted set not selected", () => carousel.SelectedBeatmapSet?.Equals(firstAdded) == false);
}
/// <summary>
/// Test adding and removing beatmap sets
/// </summary>