core: fix TestMemCachedPersist test
Problem: ``` --- FAIL: TestMemCachedPersist (0.07s) --- FAIL: TestMemCachedPersist/BoltDBStore (0.07s) testing.go:894: TempDir RemoveAll cleanup: remove C:\Users\Anna\AppData\Local\Temp\TestMemCachedPersist_BoltDBStore294966711\001\test_bolt_db: The process cannot access the file because it is being used by another process. ``` Solution: Release the resources occupied by the DB.
This commit is contained in:
parent
991f1be8e6
commit
06beb4d534
1 changed files with 4 additions and 0 deletions
|
@ -109,6 +109,10 @@ func TestMemCachedPersist(t *testing.T) {
|
|||
})
|
||||
t.Run("BoltDBStore", func(t *testing.T) {
|
||||
ps := newBoltStoreForTesting(t)
|
||||
t.Cleanup(func() {
|
||||
err := ps.Close()
|
||||
require.NoError(t, err)
|
||||
})
|
||||
testMemCachedStorePersist(t, ps)
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue