2018-07-18 09:26:08 +08:00
|
|
|
|
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
2018-07-17 05:50:22 +08:00
|
|
|
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
|
|
|
|
|
|
|
|
|
using NUnit.Framework;
|
|
|
|
|
using osu.Game.Overlays;
|
|
|
|
|
|
|
|
|
|
namespace osu.Game.Tests.Visual
|
|
|
|
|
{
|
|
|
|
|
[TestFixture]
|
|
|
|
|
public class TestCaseChangelog : OsuTestCase
|
|
|
|
|
{
|
|
|
|
|
private ChangelogOverlay changelog;
|
2018-07-18 07:35:06 +08:00
|
|
|
|
private int releaseStreamCount;
|
|
|
|
|
private int index;
|
2018-07-17 05:50:22 +08:00
|
|
|
|
|
|
|
|
|
protected override void LoadComplete()
|
|
|
|
|
{
|
|
|
|
|
base.LoadComplete();
|
|
|
|
|
|
|
|
|
|
Add(changelog = new ChangelogOverlay());
|
2018-07-18 07:35:06 +08:00
|
|
|
|
|
|
|
|
|
releaseStreamCount = changelog.streams.badgesContainer.Children.Count;
|
|
|
|
|
|
2018-07-17 21:01:53 +08:00
|
|
|
|
AddStep(@"Show", changelog.Show);
|
2018-07-18 07:35:06 +08:00
|
|
|
|
AddRepeatStep(@"Toggle Release Stream", () => {
|
|
|
|
|
changelog.streams.badgesContainer.Children[index].Activate();
|
|
|
|
|
index = (index == releaseStreamCount - 1) ? 0 : index + 1;
|
|
|
|
|
}, releaseStreamCount);
|
2018-07-17 21:01:53 +08:00
|
|
|
|
AddStep(@"Listing", changelog.header.ActivateListing);
|
2018-07-17 05:50:22 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public TestCaseChangelog()
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|