diff --git a/osu.Game/Tests/Visual/SkinnableTestScene.cs b/osu.Game/Tests/Visual/SkinnableTestScene.cs index 3d2c68c2ad..b1287fd012 100644 --- a/osu.Game/Tests/Visual/SkinnableTestScene.cs +++ b/osu.Game/Tests/Visual/SkinnableTestScene.cs @@ -52,7 +52,9 @@ private void load(AudioManager audio, SkinManager skinManager, OsuGameBase game) private readonly List createdDrawables = new List(); - public void SetContents(Func creationFunction) + public void SetContents(Func creationFunction) => SetContents(_ => creationFunction?.Invoke()); + + public void SetContents(Func creationFunction) { createdDrawables.Clear(); @@ -67,9 +69,9 @@ public void SetContents(Func creationFunction) protected IEnumerable CreatedDrawables => createdDrawables; - private Drawable createProvider(Skin skin, Func creationFunction, IBeatmap beatmap) + private Drawable createProvider(Skin skin, Func creationFunction, IBeatmap beatmap) { - var created = creationFunction(); + var created = creationFunction(skin); createdDrawables.Add(created);