mirror of
https://github.com/ppy/osu.git
synced 2025-01-27 15:43:21 +08:00
Fix ImportCollectionsTest.TestSaveAndReload
not cleaning up before/after run
This commit is contained in:
parent
a88800c99a
commit
f81e32149b
@ -128,7 +128,7 @@ namespace osu.Game.Tests.Collections.IO
|
|||||||
[Test]
|
[Test]
|
||||||
public async Task TestSaveAndReload()
|
public async Task TestSaveAndReload()
|
||||||
{
|
{
|
||||||
using (HeadlessGameHost host = new TestRunHeadlessGameHost("TestSaveAndReload", bypassCleanup: true))
|
using (HeadlessGameHost host = new CleanRunHeadlessGameHost(bypassCleanup: true))
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@ -149,7 +149,7 @@ namespace osu.Game.Tests.Collections.IO
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
using (HeadlessGameHost host = new TestRunHeadlessGameHost("TestSaveAndReload"))
|
using (HeadlessGameHost host = new TestRunHeadlessGameHost(nameof(TestSaveAndReload)))
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
@ -17,9 +17,10 @@ namespace osu.Game.Tests
|
|||||||
/// <param name="gameSuffix">An optional suffix which will isolate this host from others called from the same method source.</param>
|
/// <param name="gameSuffix">An optional suffix which will isolate this host from others called from the same method source.</param>
|
||||||
/// <param name="bindIPC">Whether to bind IPC channels.</param>
|
/// <param name="bindIPC">Whether to bind IPC channels.</param>
|
||||||
/// <param name="realtime">Whether the host should be forced to run in realtime, rather than accelerated test time.</param>
|
/// <param name="realtime">Whether the host should be forced to run in realtime, rather than accelerated test time.</param>
|
||||||
|
/// <param name="bypassCleanup">Whether to bypass directory cleanup on host disposal. Should be used only if a subsequent test relies on the files still existing.</param>
|
||||||
/// <param name="callingMethodName">The name of the calling method, used for test file isolation and clean-up.</param>
|
/// <param name="callingMethodName">The name of the calling method, used for test file isolation and clean-up.</param>
|
||||||
public CleanRunHeadlessGameHost(string gameSuffix = @"", bool bindIPC = false, bool realtime = true, [CallerMemberName] string callingMethodName = @"")
|
public CleanRunHeadlessGameHost(string gameSuffix = @"", bool bindIPC = false, bool realtime = true, bool bypassCleanup = false, [CallerMemberName] string callingMethodName = @"")
|
||||||
: base(callingMethodName + gameSuffix, bindIPC, realtime)
|
: base(callingMethodName + gameSuffix, bindIPC, realtime, bypassCleanup: bypassCleanup)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user