Update Testcase inline with framework

This commit is contained in:
EVAST9919 2017-07-09 13:39:48 +03:00
parent 6e293501e0
commit 105d57a697

View File

@ -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);