diff options
author | Jakob Unterwurzacher | 2016-06-19 20:01:29 +0200 |
---|---|---|
committer | Jakob Unterwurzacher | 2016-06-19 20:04:09 +0200 |
commit | 930e597f5ae83ea5940b7196e45404daa14bf647 (patch) | |
tree | a93598080c61cea71c620d4538bb10a488133a57 /tests/example_filesystems/example_filesystems_test.go | |
parent | f0b4d2354ddd481eed6c6b26046fe6b4e04e5d7e (diff) |
tests: expect mount failure for v0.6 and older example filesystems
Diffstat (limited to 'tests/example_filesystems/example_filesystems_test.go')
-rw-r--r-- | tests/example_filesystems/example_filesystems_test.go | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/tests/example_filesystems/example_filesystems_test.go b/tests/example_filesystems/example_filesystems_test.go index dce4558..1cf05b6 100644 --- a/tests/example_filesystems/example_filesystems_test.go +++ b/tests/example_filesystems/example_filesystems_test.go @@ -86,9 +86,10 @@ func TestExampleFSv04(t *testing.T) { if err != nil { t.Fatal(err) } - test_helpers.MountOrFatal(t, cDir, pDir, "-extpass", "echo test") - checkExampleFS(t, pDir, false) - test_helpers.Unmount(pDir) + err = test_helpers.Mount(cDir, pDir, "-extpass", "echo test") + if err == nil { + t.Errorf("Mounting deprecated FS should fail") + } test_helpers.MountOrFatal(t, cDir, pDir, "-masterkey", "74676e34-0b47c145-00dac61a-17a92316-"+ "bb57044c-e205b71f-65f4fdca-7cabd4b3", "-diriv=false", "-emenames=false", "-gcmiv128=false") checkExampleFS(t, pDir, true) @@ -108,9 +109,10 @@ func TestExampleFSv05(t *testing.T) { if err != nil { t.Fatal(err) } - test_helpers.MountOrFatal(t, cDir, pDir, "-extpass", "echo test") - checkExampleFS(t, pDir, false) - test_helpers.Unmount(pDir) + err = test_helpers.Mount(cDir, pDir, "-extpass", "echo test") + if err == nil { + t.Errorf("Mounting deprecated FS should fail") + } test_helpers.MountOrFatal(t, cDir, pDir, "-masterkey", "199eae55-36bff4af-83b9a3a2-4fa16f65-"+ "1549ccdb-2d08d1f0-b1b26965-1b61f896", "-emenames=false", "-gcmiv128=false") checkExampleFS(t, pDir, true) @@ -130,9 +132,10 @@ func TestExampleFSv06(t *testing.T) { if err != nil { t.Fatal(err) } - test_helpers.MountOrFatal(t, cDir, pDir, "-extpass", "echo test") - checkExampleFS(t, pDir, false) - test_helpers.Unmount(pDir) + err = test_helpers.Mount(cDir, pDir, "-extpass", "echo test") + if err == nil { + t.Errorf("Mounting deprecated FS should fail") + } test_helpers.MountOrFatal(t, cDir, pDir, "-masterkey", "7bc8deb0-5fc894ef-a093da43-61561a81-"+ "0e8dee83-fdc056a4-937c37dd-9df5c520", "-gcmiv128=false") checkExampleFS(t, pDir, true) @@ -154,9 +157,10 @@ func TestExampleFSv06PlaintextNames(t *testing.T) { if err != nil { t.Fatal(err) } - test_helpers.MountOrFatal(t, cDir, pDir, "-extpass", "echo test") - checkExampleFS(t, pDir, false) - test_helpers.Unmount(pDir) + err = test_helpers.Mount(cDir, pDir, "-extpass", "echo test") + if err == nil { + t.Errorf("Mounting deprecated FS should fail") + } test_helpers.MountOrFatal(t, cDir, pDir, "-masterkey", "f4690202-595e4593-64c4f7e0-4dddd7d1-"+ "303147f9-0ca8aea2-966341a7-52ea8ae9", "-plaintextnames", "-gcmiv128=false") checkExampleFS(t, pDir, true) |