Skip to content

Commit

Permalink
Merge pull request #2205 from smoogipoo/test-beatmap
Browse files Browse the repository at this point in the history
Move test beatmap from TestCasePlayer into an instantiable class
  • Loading branch information
peppy committed Mar 13, 2018
2 parents afeab48 + e9cd97c commit c0248e1
Show file tree
Hide file tree
Showing 7 changed files with 757 additions and 723 deletions.
8 changes: 3 additions & 5 deletions osu.Game.Rulesets.Catch/Tests/TestCaseBananaShower.cs
Expand Up @@ -28,16 +28,14 @@ public TestCaseBananaShower()
{
}

protected override Beatmap CreateBeatmap()
protected override Beatmap CreateBeatmap(Ruleset ruleset)
{
var beatmap = new Beatmap
{
BeatmapInfo = new BeatmapInfo
{
BaseDifficulty = new BeatmapDifficulty
{
CircleSize = 6,
}
BaseDifficulty = new BeatmapDifficulty { CircleSize = 6 },
Ruleset = ruleset.RulesetInfo
}
};

Expand Down
9 changes: 4 additions & 5 deletions osu.Game.Rulesets.Catch/Tests/TestCaseCatchStacker.cs
Expand Up @@ -15,19 +15,18 @@ public TestCaseCatchStacker()
{
}

protected override Beatmap CreateBeatmap()
protected override Beatmap CreateBeatmap(Ruleset ruleset)
{
var beatmap = new Beatmap
{
BeatmapInfo = new BeatmapInfo
{
BaseDifficulty = new BeatmapDifficulty
{
CircleSize = 6,
}
BaseDifficulty = new BeatmapDifficulty { CircleSize = 6 },
Ruleset = ruleset.RulesetInfo
}
};


for (int i = 0; i < 512; i++)
beatmap.HitObjects.Add(new Fruit { X = 0.5f + i / 2048f * (i % 10 - 5), StartTime = i * 100, NewCombo = i % 8 == 0 });

Expand Down
5 changes: 3 additions & 2 deletions osu.Game.Rulesets.Catch/Tests/TestCaseHyperdash.cs
Expand Up @@ -15,9 +15,10 @@ public TestCaseHyperdash()
{
}

protected override Beatmap CreateBeatmap()
protected override Beatmap CreateBeatmap(Ruleset ruleset)
{
var beatmap = new Beatmap();
var beatmap = new Beatmap { BeatmapInfo = { Ruleset = ruleset.RulesetInfo } };


for (int i = 0; i < 512; i++)
if (i % 5 < 3)
Expand Down

0 comments on commit c0248e1

Please sign in to comment.