Skip to content

Commit

Permalink
add Close test calls
Browse files Browse the repository at this point in the history
  • Loading branch information
kukymbr committed Mar 4, 2024
1 parent 78b52f5 commit 3ce96f9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions filecache_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ func TestNew_WhenValid_ExpectNoError(t *testing.T) {
assert.NotEmpty(t, fc.GetPath())
assert.NotEqual(t, ".", fc.GetPath())
assert.DirExists(t, fc.GetPath(), i)

err = fc.Close()

assert.NoError(t, err)
}
}

Expand Down
4 changes: 4 additions & 0 deletions gcinterval_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,8 @@ func TestIntervalGarbageCollector(t *testing.T) {
assert.NoFileExists(t, "./testdata/gc/test1.cache--meta")
assert.FileExists(t, "./testdata/gc/test2.cache")
assert.FileExists(t, "./testdata/gc/test2.cache--meta")

err := gc.Close()

assert.NoError(t, err)
}

0 comments on commit 3ce96f9

Please sign in to comment.