mirror of
https://github.com/ppy/osu.git
synced 2025-01-28 06:42:54 +08:00
Add test coverage
This commit is contained in:
parent
2ce9599957
commit
ee664ad571
@ -131,6 +131,18 @@ namespace osu.Game.Tests.Visual.UserInterface
|
||||
AddAssert("ensure mods not selected", () => modDisplay.Current.Value.Count == 0);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestExternallySetCustomizedMod()
|
||||
{
|
||||
AddStep("set customized mod externally", () => SelectedMods.Value = new[] { new OsuModDoubleTime { SpeedChange = { Value = 1.01 } } });
|
||||
|
||||
AddAssert("ensure button is selected and customized accordingly", () =>
|
||||
{
|
||||
var button = modSelect.GetModButton(SelectedMods.Value.Single());
|
||||
return ((OsuModDoubleTime)button.SelectedMod).SpeedChange.Value == 1.01;
|
||||
});
|
||||
}
|
||||
|
||||
private void testSingleMod(Mod mod)
|
||||
{
|
||||
selectNext(mod);
|
||||
|
Loading…
Reference in New Issue
Block a user