mirror of
https://github.com/osukey/osukey.git
synced 2025-07-03 01:09:57 +09:00
Add a catch specific player test
This commit is contained in:
@ -16,7 +16,7 @@ using OpenTK.Graphics;
|
||||
|
||||
namespace osu.Game.Tests.Visual
|
||||
{
|
||||
internal class TestCasePlayer : OsuTestCase
|
||||
public class TestCasePlayer : OsuTestCase
|
||||
{
|
||||
protected Player Player;
|
||||
private RulesetStore rulesets;
|
||||
@ -45,7 +45,7 @@ namespace osu.Game.Tests.Visual
|
||||
loadPlayerFor(rulesets.Query<RulesetInfo>().First());
|
||||
}
|
||||
|
||||
private void loadPlayerFor(RulesetInfo r)
|
||||
protected virtual Beatmap CreateBeatmap()
|
||||
{
|
||||
Beatmap beatmap;
|
||||
|
||||
@ -53,6 +53,13 @@ namespace osu.Game.Tests.Visual
|
||||
using (var reader = new StreamReader(stream))
|
||||
beatmap = BeatmapDecoder.GetDecoder(reader).Decode(reader);
|
||||
|
||||
return beatmap;
|
||||
}
|
||||
|
||||
private void loadPlayerFor(RulesetInfo r)
|
||||
{
|
||||
var beatmap = CreateBeatmap();
|
||||
|
||||
beatmap.BeatmapInfo.Ruleset = r;
|
||||
|
||||
var instance = r.CreateInstance();
|
||||
|
Reference in New Issue
Block a user