1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 21:02:55 +08:00

Don't reinitialise fake data if we've already populated it.

This commit is contained in:
Dean Herbert 2016-10-27 17:38:38 +09:00
parent ace31c68ea
commit d664c97279

View File

@ -24,16 +24,19 @@ namespace osu.Desktop.Tests
{
base.Reset();
storage = new TestStorage(@"TestCasePlaySongSelect");
db = new BeatmapDatabase(storage);
if (db == null)
{
storage = new TestStorage(@"TestCasePlaySongSelect");
db = new BeatmapDatabase(storage);
var sets = new List<BeatmapSetInfo>();
for (int i = 0; i < 100; i += 10)
sets.Add(createTestBeatmapSet(i));
var sets = new List<BeatmapSetInfo>();
for (int i = 0; i < 100; i += 10)
sets.Add(createTestBeatmapSet(i));
db.Import(sets);
}
db.Import(sets);
Add(new PlaySongSelect(db));
}