1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-13 03:57:24 +08:00
osu-lazer/osu.Desktop.VisualTests/Tests/TestCaseModSelectOverlay.cs
2017-04-15 05:22:41 +09:00

35 lines
1.0 KiB
C#

// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using osu.Framework.Graphics;
using osu.Game.Overlays.Mods;
using osu.Framework.Testing;
using osu.Game.Modes;
namespace osu.Desktop.VisualTests.Tests
{
internal class TestCaseModSelectOverlay : TestCase
{
public override string Description => @"Tests the mod select overlay";
private ModSelectOverlay modSelect;
public override void Reset()
{
base.Reset();
Add(modSelect = new ModSelectOverlay
{
RelativeSizeAxes = Axes.X,
Origin = Anchor.BottomCentre,
Anchor = Anchor.BottomCentre,
});
AddStep("Toggle", modSelect.ToggleVisibility);
foreach (var ruleset in RulesetCollection.AllRulesets)
AddStep(ruleset.Description, () => modSelect.Ruleset.Value = ruleset);
}
}
}