From df17f1d702bea709228b9923a8ed2fc19005ba43 Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Mon, 11 Jul 2016 20:40:53 +0200 Subject: [PATCH] tests: add verbose output when unmounting --- tests/example_filesystems/example_filesystems_test.go | 2 +- tests/test_helpers/helpers.go | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/example_filesystems/example_filesystems_test.go b/tests/example_filesystems/example_filesystems_test.go index e38d3e6..8b01555 100644 --- a/tests/example_filesystems/example_filesystems_test.go +++ b/tests/example_filesystems/example_filesystems_test.go @@ -24,7 +24,7 @@ func TestMain(m *testing.M) { flag.Parse() for _, opensslOpt = range []string{"-openssl=false", "-openssl=true"} { if testing.Verbose() { - fmt.Printf("TestMain: testing with %q\n", opensslOpt) + fmt.Printf("example_filesystems: testing with %q\n", opensslOpt) } test_helpers.ResetTmpDir(true) r := m.Run() diff --git a/tests/test_helpers/helpers.go b/tests/test_helpers/helpers.go index b42adcd..bad5675 100644 --- a/tests/test_helpers/helpers.go +++ b/tests/test_helpers/helpers.go @@ -49,6 +49,9 @@ func ResetTmpDir(plaintextNames bool) { d := filepath.Join(TmpDir, e.Name()) err = os.Remove(d) if err != nil { + if testing.Verbose() { + fmt.Printf("%v, trying umount\n", d, err) + } UnmountErr(d) err = os.RemoveAll(d) if err != nil {