mirror of
https://github.com/osukey/osukey.git
synced 2025-08-03 14:46:38 +09:00
Fix multiple tests via null checks and changing ToLive
to Detach
flow
This commit is contained in:
@ -59,8 +59,15 @@ namespace osu.Game.Stores
|
||||
beatmapSet.Beatmaps.AddRange(createBeatmapDifficulties(beatmapSet.Files, realm));
|
||||
|
||||
foreach (BeatmapInfo b in beatmapSet.Beatmaps)
|
||||
{
|
||||
b.BeatmapSet = beatmapSet;
|
||||
|
||||
// ensure we aren't trying to add a new ruleset to the database
|
||||
// this can happen in tests, mostly
|
||||
if (!b.Ruleset.IsManaged)
|
||||
b.Ruleset = realm.Find<RulesetInfo>(b.Ruleset.ShortName);
|
||||
}
|
||||
|
||||
validateOnlineIds(beatmapSet, realm);
|
||||
|
||||
bool hadOnlineIDs = beatmapSet.Beatmaps.Any(b => b.OnlineID > 0);
|
||||
|
Reference in New Issue
Block a user