mirror of
https://github.com/osukey/osukey.git
synced 2025-05-03 20:57:28 +09:00
Only run prompt-for-save test logic when relevant
This commit is contained in:
parent
35ee889e5b
commit
cbb9ff1c49
@ -98,8 +98,11 @@ namespace osu.Game.Tests.Visual.Editing
|
|||||||
|
|
||||||
AddStep("exit editor", () => Stack.Exit());
|
AddStep("exit editor", () => Stack.Exit());
|
||||||
|
|
||||||
AddUntilStep("prompt for save dialog shown", () => DialogOverlay.CurrentDialog is PromptForSaveDialog);
|
if (sameRuleset)
|
||||||
AddStep("discard changes", () => ((PromptForSaveDialog)DialogOverlay.CurrentDialog).PerformOkAction());
|
{
|
||||||
|
AddUntilStep("prompt for save dialog shown", () => DialogOverlay.CurrentDialog is PromptForSaveDialog);
|
||||||
|
AddStep("discard changes", () => ((PromptForSaveDialog)DialogOverlay.CurrentDialog).PerformOkAction());
|
||||||
|
}
|
||||||
|
|
||||||
// ensure editor loader didn't resume.
|
// ensure editor loader didn't resume.
|
||||||
AddAssert("stack empty", () => Stack.CurrentScreen == null);
|
AddAssert("stack empty", () => Stack.CurrentScreen == null);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user