mirror of
https://github.com/ppy/osu.git
synced 2025-01-28 09:02:58 +08:00
add test coverage
This commit is contained in:
parent
bf5a7e3f2a
commit
a03cfbc2d4
@ -157,6 +157,26 @@ namespace osu.Game.Tests.Visual.Multiplayer
|
||||
AddUntilStep("3 rooms visible", () => container.Rooms.Count(r => r.IsPresent) == 3);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestLockedFiltering()
|
||||
{
|
||||
AddStep("add rooms", () =>
|
||||
{
|
||||
RoomManager.AddRooms(1, withPassword: true);
|
||||
RoomManager.AddRooms(1, withPassword: false);
|
||||
});
|
||||
|
||||
AddUntilStep("both rooms shown", () => container.Rooms.Count(r => r.IsPresent) == 2);
|
||||
|
||||
AddStep("filter locked rooms", () => container.Filter.Value = new FilterCriteria { Locked = false });
|
||||
|
||||
AddUntilStep("locked room hidden", () => container.Rooms.All(r => !r.Room.HasPassword.Value));
|
||||
|
||||
AddStep("unfilter locked rooms", () => container.Filter.SetDefault());
|
||||
|
||||
AddUntilStep("both rooms shown", () => container.Rooms.Count(r => r.IsPresent) == 2);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestPasswordProtectedRooms()
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user