mirror of
https://github.com/pgsty/minio.git
synced 2026-07-19 12:10:24 +03:00
tests: add unit test for posix functions. (#2037)
Unit tests for posix operations. * MakeVol * DeleteVol * StatVol * ListVols * DeleteFile * AppendFile * RenameFile * StatFile Fixes #2021
This commit is contained in:
@@ -97,9 +97,8 @@ func TestUNCPathENOTDIR(t *testing.T) {
|
||||
// Try to create a file that includes a file in its path components.
|
||||
// In *nix, this returns syscall.ENOTDIR while in windows we receive the following error.
|
||||
err = fs.AppendFile("voldir", "/file/obj1", []byte("hello"))
|
||||
winErr := "The system cannot find the path specified."
|
||||
if !strings.Contains(err.Error(), winErr) {
|
||||
t.Errorf("expected to recieve %s, but received %s", winErr, err.Error())
|
||||
if err != errFileAccessDenied {
|
||||
t.Errorf("expected: %s, got: %s", errFileAccessDenied, err)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user