1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 10:33:30 +08:00

Add test coverage

This commit is contained in:
Bartłomiej Dach 2024-01-15 19:05:33 +01:00
parent d8962ddff8
commit e8394e6f74
No known key found for this signature in database

View File

@ -542,6 +542,11 @@ namespace osu.Game.Tests.Visual.UserInterface
AddStep("press enter", () => InputManager.Key(Key.Enter)); AddStep("press enter", () => InputManager.Key(Key.Enter));
AddAssert("hidden selected", () => getPanelForMod(typeof(OsuModHidden)).Active.Value); AddAssert("hidden selected", () => getPanelForMod(typeof(OsuModHidden)).Active.Value);
AddAssert("all text selected in textbox", () =>
{
var textBox = modSelectOverlay.ChildrenOfType<SearchTextBox>().Single();
return textBox.SelectedText == textBox.Text;
});
AddStep("press enter again", () => InputManager.Key(Key.Enter)); AddStep("press enter again", () => InputManager.Key(Key.Enter));
AddAssert("hidden deselected", () => !getPanelForMod(typeof(OsuModHidden)).Active.Value); AddAssert("hidden deselected", () => !getPanelForMod(typeof(OsuModHidden)).Active.Value);