diff --git a/osu.Desktop.VisualTests/Tests/TestCaseBeatSyncedContainer.cs b/osu.Desktop.VisualTests/Tests/TestCaseBeatSyncedContainer.cs index c0d2b04bcb..9bf307b1ce 100644 --- a/osu.Desktop.VisualTests/Tests/TestCaseBeatSyncedContainer.cs +++ b/osu.Desktop.VisualTests/Tests/TestCaseBeatSyncedContainer.cs @@ -15,6 +15,7 @@ using osu.Game.Graphics.Sprites; using osu.Framework.Lists; using System; using System.Globalization; +using osu.Framework.Allocation; namespace osu.Desktop.VisualTests.Tests { @@ -27,11 +28,6 @@ namespace osu.Desktop.VisualTests.Tests public TestCaseBeatSyncedContainer() { Clock = new FramedClock(); - } - - public override void Reset() - { - base.Reset(); Clock.ProcessFrame(); Add(new BeatContainer @@ -45,7 +41,12 @@ namespace osu.Desktop.VisualTests.Tests Origin = Anchor.TopRight, Anchor = Anchor.TopRight, }); - mc.State = Visibility.Visible; + } + + [BackgroundDependencyLoader] + private void load() + { + mc.ToggleVisibility(); } private class BeatContainer : BeatSyncedContainer @@ -141,6 +142,8 @@ namespace osu.Desktop.VisualTests.Tests { base.OnNewBeat(beatIndex, timingPoint, effectPoint, amplitudes); + if (beatIndex < 0) return; + timingPointCount.Value = timingPoints.Count; currentTimingPoint.Value = timingPoints.IndexOf(timingPoint) + 1; beatCount.Value = calculateBeatCount(timingPoint);