summaryrefslogtreecommitdiff
path: root/tests/example_filesystems
diff options
context:
space:
mode:
Diffstat (limited to 'tests/example_filesystems')
-rw-r--r--tests/example_filesystems/example_filesystems_test.go28
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)