mirror of
https://github.com/Thealexbarney/LibHac.git
synced 2024-11-14 10:49:41 +01:00
34 lines
918 B
C#
34 lines
918 B
C#
using System.Diagnostics;
|
|
using LibHac.Fs;
|
|
using LibHac.FsSystem;
|
|
using LibHac.Tests.Fs.IFileSystemTestBase;
|
|
|
|
namespace LibHac.Tests.Fs
|
|
{
|
|
public class SubdirectoryFileSystemTests : IFileSystemTests
|
|
{
|
|
protected override IFileSystem CreateFileSystem()
|
|
{
|
|
Trace.Listeners.Clear();
|
|
var baseFs = new InMemoryFileSystem();
|
|
baseFs.CreateDirectory("/sub");
|
|
baseFs.CreateDirectory("/sub/path");
|
|
|
|
var subFs = new SubdirectoryFileSystem(baseFs, "/sub/path");
|
|
|
|
return subFs;
|
|
}
|
|
}
|
|
public class SubdirectoryFileSystemTestsRoot : IFileSystemTests
|
|
{
|
|
protected override IFileSystem CreateFileSystem()
|
|
{
|
|
Trace.Listeners.Clear();
|
|
var baseFs = new InMemoryFileSystem();
|
|
|
|
var subFs = new SubdirectoryFileSystem(baseFs, "/");
|
|
|
|
return subFs;
|
|
}
|
|
}
|
|
}
|