mirror of
https://github.com/ppy/osu
synced 2024-12-14 10:57:41 +00:00
Change boolean argument to HitResult
instead
This commit is contained in:
parent
cccc9d7d39
commit
1676c2c3f6
@ -174,8 +174,9 @@ namespace osu.Game.Tests.Gameplay
|
||||
AddAssert("failed", () => processor.HasFailed);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestMultipleFailConditions([Values] bool applyFirstCondition)
|
||||
[TestCase(HitResult.Miss)]
|
||||
[TestCase(HitResult.Meh)]
|
||||
public void TestMultipleFailConditions(HitResult resultApplied)
|
||||
{
|
||||
var beatmap = createBeatmap(0, 1000);
|
||||
createProcessor(beatmap);
|
||||
@ -189,11 +190,7 @@ namespace osu.Game.Tests.Gameplay
|
||||
AddStep("apply perfect hit result", () => processor.ApplyResult(new JudgementResult(beatmap.HitObjects[0], new Judgement()) { Type = HitResult.Perfect }));
|
||||
AddAssert("not failed", () => !processor.HasFailed);
|
||||
|
||||
if (applyFirstCondition)
|
||||
AddStep("apply miss hit result", () => processor.ApplyResult(new JudgementResult(beatmap.HitObjects[0], new Judgement()) { Type = HitResult.Miss }));
|
||||
else
|
||||
AddStep("apply meh hit result", () => processor.ApplyResult(new JudgementResult(beatmap.HitObjects[0], new Judgement()) { Type = HitResult.Meh }));
|
||||
|
||||
AddStep($"apply {resultApplied.ToString().ToLower()} hit result", () => processor.ApplyResult(new JudgementResult(beatmap.HitObjects[0], new Judgement()) { Type = HitResult.Miss }));
|
||||
AddAssert("failed", () => processor.HasFailed);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user