2019-05-12 15:36:05 +00:00
|
|
|
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
|
|
|
|
// See the LICENCE file in the repository root for full licence text.
|
|
|
|
|
|
2018-07-16 21:50:22 +00:00
|
|
|
|
using NUnit.Framework;
|
2018-07-25 12:31:41 +00:00
|
|
|
|
using osu.Game.Online.API.Requests.Responses;
|
2018-07-16 21:50:22 +00:00
|
|
|
|
using osu.Game.Overlays;
|
|
|
|
|
|
|
|
|
|
namespace osu.Game.Tests.Visual
|
|
|
|
|
{
|
|
|
|
|
[TestFixture]
|
2018-07-24 18:13:53 +00:00
|
|
|
|
public class TestCaseChangelogOverlay : OsuTestCase
|
2018-07-16 21:50:22 +00:00
|
|
|
|
{
|
|
|
|
|
private ChangelogOverlay changelog;
|
|
|
|
|
|
|
|
|
|
protected override void LoadComplete()
|
|
|
|
|
{
|
|
|
|
|
base.LoadComplete();
|
|
|
|
|
|
|
|
|
|
Add(changelog = new ChangelogOverlay());
|
2018-07-22 19:00:29 +00:00
|
|
|
|
AddStep(@"Show", changelog.Show);
|
2018-07-25 12:31:41 +00:00
|
|
|
|
AddStep(@"Hide", changelog.Hide);
|
2019-05-12 15:46:22 +00:00
|
|
|
|
|
|
|
|
|
AddWaitStep("wait for hide", 3);
|
|
|
|
|
|
2018-07-25 12:31:41 +00:00
|
|
|
|
AddStep(@"Show with Lazer 2018.712.0", () =>
|
|
|
|
|
{
|
2018-10-18 19:04:21 +00:00
|
|
|
|
changelog.FetchAndShowBuild(new APIChangelogBuild
|
2018-07-25 12:31:41 +00:00
|
|
|
|
{
|
|
|
|
|
Version = "2018.712.0",
|
|
|
|
|
UpdateStream = new UpdateStream { Name = "lazer" },
|
|
|
|
|
});
|
|
|
|
|
changelog.Show();
|
|
|
|
|
});
|
2019-05-12 15:46:22 +00:00
|
|
|
|
|
|
|
|
|
AddWaitStep("wait for show", 3);
|
2018-07-25 12:31:41 +00:00
|
|
|
|
AddStep(@"Hide", changelog.Hide);
|
2019-05-12 15:46:22 +00:00
|
|
|
|
AddWaitStep("wait for hide", 3);
|
|
|
|
|
|
2018-07-25 12:31:41 +00:00
|
|
|
|
AddStep(@"Show with listing", () =>
|
|
|
|
|
{
|
|
|
|
|
changelog.ShowListing();
|
|
|
|
|
changelog.Show();
|
|
|
|
|
});
|
2018-07-16 21:50:22 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|