mirror of
https://github.com/osukey/osukey.git
synced 2025-06-08 21:07:59 +09:00
Fix regression in tournament test startup behaviour
This commit is contained in:
parent
7d057ab6ce
commit
13aaf766f9
@ -13,8 +13,8 @@ namespace osu.Game.Tournament.Tests
|
|||||||
{
|
{
|
||||||
base.LoadComplete();
|
base.LoadComplete();
|
||||||
|
|
||||||
BracketLoadTask.Wait();
|
BracketLoadTask.ContinueWith(_ => Schedule(() =>
|
||||||
|
{
|
||||||
LoadComponentAsync(new Background("Menu/menu-background-0")
|
LoadComponentAsync(new Background("Menu/menu-background-0")
|
||||||
{
|
{
|
||||||
Colour = OsuColour.Gray(0.5f),
|
Colour = OsuColour.Gray(0.5f),
|
||||||
@ -24,6 +24,7 @@ namespace osu.Game.Tournament.Tests
|
|||||||
// Have to construct this here, rather than in the constructor, because
|
// Have to construct this here, rather than in the constructor, because
|
||||||
// we depend on some dependencies to be loaded within OsuGameBase.load().
|
// we depend on some dependencies to be loaded within OsuGameBase.load().
|
||||||
Add(new TestBrowser());
|
Add(new TestBrowser());
|
||||||
|
}));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -154,12 +154,13 @@ namespace osu.Game.Tournament.Tests
|
|||||||
|
|
||||||
protected override void LoadAsyncComplete()
|
protected override void LoadAsyncComplete()
|
||||||
{
|
{
|
||||||
BracketLoadTask.Wait();
|
BracketLoadTask.ContinueWith(_ => Schedule(() =>
|
||||||
|
{
|
||||||
// this has to be run here rather than LoadComplete because
|
// this has to be run here rather than LoadComplete because
|
||||||
// TestScene.cs is checking the IsLoaded state (on another thread) and expects
|
// TestScene.cs is checking the IsLoaded state (on another thread) and expects
|
||||||
// the runner to be loaded at that point.
|
// the runner to be loaded at that point.
|
||||||
Add(runner = new TestSceneTestRunner.TestRunner());
|
Add(runner = new TestSceneTestRunner.TestRunner());
|
||||||
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
public void RunTestBlocking(TestScene test) => runner.RunTestBlocking(test);
|
public void RunTestBlocking(TestScene test) => runner.RunTestBlocking(test);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user