LibHac/tests/LibHac.Tests/Fs/IFileSystemTestBase/IFileSystemTests.OpenDirectory.cs
2020-03-08 01:00:02 -07:00

21 lines
No EOL
546 B
C#

using LibHac.Common;
using LibHac.Fs;
using Xunit;
namespace LibHac.Tests.Fs.IFileSystemTestBase
{
public abstract partial class IFileSystemTests
{
[Fact]
public void OpenDirectory_PathIsFile_ReturnsPathNotFound()
{
IFileSystem fs = CreateFileSystem();
fs.CreateFile("/file".ToU8Span(), 0, CreateFileOptions.None);
Result rc = fs.OpenDirectory(out _, "/file".ToU8Span(), OpenDirectoryMode.All);
Assert.Equal(ResultFs.PathNotFound.Value, rc);
}
}
}