mirror of
https://github.com/osukey/osukey.git
synced 2025-08-04 23:24:04 +09:00
Update Legacy components to not require skin in ctor
This commit is contained in:
@ -2,10 +2,12 @@
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using NUnit.Framework;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Testing;
|
||||
using osu.Game.Rulesets;
|
||||
using osu.Game.Rulesets.Osu;
|
||||
using osu.Game.Skinning;
|
||||
using osu.Game.Skinning.Editor;
|
||||
|
||||
namespace osu.Game.Tests.Visual.Gameplay
|
||||
@ -14,12 +16,22 @@ namespace osu.Game.Tests.Visual.Gameplay
|
||||
{
|
||||
private SkinEditor skinEditor;
|
||||
|
||||
[Resolved]
|
||||
private SkinManager skinManager { get; set; }
|
||||
|
||||
[SetUpSteps]
|
||||
public override void SetUpSteps()
|
||||
{
|
||||
AddStep("set empty legacy skin", () =>
|
||||
{
|
||||
var imported = skinManager.Import(new SkinInfo { Name = "test skin" }).Result;
|
||||
|
||||
skinManager.CurrentSkinInfo.Value = imported;
|
||||
});
|
||||
|
||||
base.SetUpSteps();
|
||||
|
||||
AddStep("add editor overlay", () =>
|
||||
AddStep("reload skin editor", () =>
|
||||
{
|
||||
skinEditor?.Expire();
|
||||
Player.ScaleTo(SkinEditorOverlay.VISIBLE_TARGET_SCALE);
|
||||
|
Reference in New Issue
Block a user