1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-18 10:32:56 +08:00
osu-lazer/osu.Game.Rulesets.Osu.Tests/Mods/TestSceneOsuModPerfect.cs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

55 lines
1.6 KiB
C#
Raw Normal View History

2020-03-02 11:42:48 +08:00
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using NUnit.Framework;
using osu.Game.Rulesets.Objects;
using osu.Game.Rulesets.Objects.Types;
using osu.Game.Rulesets.Osu.Mods;
using osu.Game.Rulesets.Osu.Objects;
using osu.Game.Tests.Visual;
using osuTK;
2020-03-03 14:30:53 +08:00
namespace osu.Game.Rulesets.Osu.Tests.Mods
2020-03-02 11:42:48 +08:00
{
public partial class TestSceneOsuModPerfect : ModPerfectTestScene
{
protected override Ruleset CreatePlayerRuleset() => new OsuRuleset();
2020-03-02 11:42:48 +08:00
public TestSceneOsuModPerfect()
: base(new OsuModPerfect())
2020-03-02 11:42:48 +08:00
{
}
[TestCase(false)]
[TestCase(true)]
2020-03-10 23:36:56 +08:00
public void TestHitCircle(bool shouldMiss) => CreateHitObjectTest(new HitObjectTestData(new HitCircle { StartTime = 1000 }), shouldMiss);
2020-03-02 11:42:48 +08:00
[TestCase(false)]
[TestCase(true)]
public void TestSlider(bool shouldMiss)
{
var slider = new Slider
{
StartTime = 1000,
Path = new SliderPath(PathType.LINEAR, new[] { Vector2.Zero, new Vector2(100, 0), })
2020-03-02 11:42:48 +08:00
};
2020-03-10 23:36:56 +08:00
CreateHitObjectTest(new HitObjectTestData(slider), shouldMiss);
2020-03-02 11:42:48 +08:00
}
[TestCase(false)]
[TestCase(true)]
public void TestSpinner(bool shouldMiss)
{
var spinner = new Spinner
{
StartTime = 1000,
EndTime = 3000,
Position = new Vector2(256, 192)
};
2020-03-10 23:36:56 +08:00
CreateHitObjectTest(new HitObjectTestData(spinner), shouldMiss);
2020-03-02 11:42:48 +08:00
}
}
}