diff options
author | Jakob Unterwurzacher | 2015-10-31 13:45:14 +0100 |
---|---|---|
committer | Jakob Unterwurzacher | 2015-11-01 01:36:19 +0100 |
commit | 3e3685127340571dca40f0c16cbaa3d272689f4f (patch) | |
tree | 4f7a5ef278ff9b3c09547a1195d5fdbe914e5e3c | |
parent | eac1f5421375913b871132d389dc69393a9ac232 (diff) |
TestRmwRace: abort testing on write failures
Continuing the test will just generate useless noise
-rw-r--r-- | main_test.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/main_test.go b/main_test.go index 8ae7b12..b5b2d35 100644 --- a/main_test.go +++ b/main_test.go @@ -232,11 +232,11 @@ func TestRmwRace(t *testing.T) { fn := plainDir + "rmwrace" f1, err := os.Create(fn) if err != nil { - t.Errorf("file create failed") + t.Fatalf("file create failed") } f2, err := os.Create(fn) if err != nil { - t.Errorf("file create failed") + t.Fatalf("file create failed") } oldBlock := bytes.Repeat([]byte("o"), 4096) @@ -255,7 +255,7 @@ func TestRmwRace(t *testing.T) { // Reset to [ooooooooo] _, err = f1.WriteAt(oldBlock, 0) if err != nil { - t.Errorf("Write failed") + t.Fatalf("Write failed") } var wg sync.WaitGroup |