Add failing test for legacy online ID decoding

This commit is contained in:
Bartłomiej Dach 2023-09-01 08:04:35 +02:00
parent c1a817fec6
commit bfcb4f4f2d
No known key found for this signature in database
2 changed files with 14 additions and 0 deletions

View File

@ -87,6 +87,20 @@ namespace osu.Game.Tests.Beatmaps.Formats
}
}
[Test]
public void TestDecodeLegacyOnlineID()
{
var decoder = new TestLegacyScoreDecoder();
using (var resourceStream = TestResources.OpenResource("Replays/taiko-replay-with-legacy-online-id.osr"))
{
var score = decoder.Parse(resourceStream);
Assert.That(score.ScoreInfo.OnlineID, Is.EqualTo(-1));
Assert.That(score.ScoreInfo.LegacyOnlineID, Is.EqualTo(255));
}
}
[TestCase(3, true)]
[TestCase(6, false)]
[TestCase(LegacyBeatmapDecoder.LATEST_VERSION, false)]