mirror of
https://github.com/ppy/osu.git
synced 2025-01-28 06:42:54 +08:00
Delete test case covering beatmap detach scenario
Due to being fundamentally incompatible with the `Debug.Fail()` call added in99e55bb9c0
. This reverts commit4ecc724841
.
This commit is contained in:
parent
99e55bb9c0
commit
6ce0ca832e
@ -1,6 +1,8 @@
|
|||||||
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
// 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.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using NUnit.Framework;
|
using NUnit.Framework;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
@ -94,33 +96,6 @@ namespace osu.Game.Tests.Visual.Editing
|
|||||||
AddAssert("Beatmap still has correct timeline zoom", () => EditorBeatmap.BeatmapInfo.TimelineZoom == changedTimelineZoom);
|
AddAssert("Beatmap still has correct timeline zoom", () => EditorBeatmap.BeatmapInfo.TimelineZoom == changedTimelineZoom);
|
||||||
}
|
}
|
||||||
|
|
||||||
[Test]
|
|
||||||
public void TestSaveWithDetachedBeatmap()
|
|
||||||
{
|
|
||||||
AddStep("Set overall difficulty", () => EditorBeatmap.Difficulty.OverallDifficulty = 7);
|
|
||||||
|
|
||||||
SaveEditor();
|
|
||||||
|
|
||||||
AddStep("Detach beatmap from set", () =>
|
|
||||||
{
|
|
||||||
Realm.Write(r =>
|
|
||||||
{
|
|
||||||
BeatmapSetInfo? beatmapSet = r.Find<BeatmapSetInfo>(EditorBeatmap.BeatmapInfo.BeatmapSet!.ID);
|
|
||||||
BeatmapInfo? beatmap = r.Find<BeatmapInfo>(EditorBeatmap.BeatmapInfo.ID);
|
|
||||||
|
|
||||||
beatmapSet.Beatmaps.Remove(beatmap);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
SaveEditor();
|
|
||||||
|
|
||||||
AddAssert("Beatmap has correct overall difficulty", () => EditorBeatmap.Difficulty.OverallDifficulty == 7);
|
|
||||||
|
|
||||||
ReloadEditorToSameBeatmap();
|
|
||||||
|
|
||||||
AddAssert("Beatmap still has correct overall difficulty", () => EditorBeatmap.Difficulty.OverallDifficulty == 7);
|
|
||||||
}
|
|
||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
public void TestDifficulty()
|
public void TestDifficulty()
|
||||||
{
|
{
|
||||||
@ -155,7 +130,7 @@ namespace osu.Game.Tests.Visual.Editing
|
|||||||
[Test]
|
[Test]
|
||||||
public void TestLengthAndStarRatingUpdated()
|
public void TestLengthAndStarRatingUpdated()
|
||||||
{
|
{
|
||||||
WorkingBeatmap working = null!;
|
WorkingBeatmap working = null;
|
||||||
double lastStarRating = 0;
|
double lastStarRating = 0;
|
||||||
double lastLength = 0;
|
double lastLength = 0;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user