Skip to content

Commit

Permalink
TestZFSUsage: use t.TempDir()
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
  • Loading branch information
thaJeztah committed May 25, 2023
1 parent 6e9c675 commit 5e3457b
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions zfs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,7 @@ func TestZFSUsage(t *testing.T) {
ctx := context.Background()

// Create temporary directory
root, err := os.MkdirTemp("", "TestZFSUsage-")
if err != nil {
t.Error(err)
}
defer os.RemoveAll(root)
root := t.TempDir()

// Create the snapshotter
z, closer, err := newSnapshotter()(ctx, root)
Expand Down

0 comments on commit 5e3457b

Please sign in to comment.