Merge pull request #6100 from jonyhy96/cleanup-test

This commit is contained in:
Fu Wei 2021-10-09 18:54:16 +08:00 committed by GitHub
commit 193bafc42c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -196,7 +196,14 @@ func TestBtrfsMounts(t *testing.T) {
} }
defer testutil.Unmount(t, target) defer testutil.Unmount(t, target)
// TODO(stevvooe): Verify contents of "foo" bs, err := os.ReadFile(filepath.Join(target, "foo"))
if err != nil {
t.Fatal(err)
}
if string(bs) != "content" {
t.Fatalf("wrong content in foo want: content, got: %s", bs)
}
if err := os.WriteFile(filepath.Join(target, "bar"), []byte("content"), 0777); err != nil { if err := os.WriteFile(filepath.Join(target, "bar"), []byte("content"), 0777); err != nil {
t.Fatal(err) t.Fatal(err)
} }