mirror of
https://github.com/gogrlx/nats-server.git
synced 2026-04-02 03:38:42 -07:00
test: delay slightly between filestore test permutations
This is to try to prevent test failing due to trying to access the tempdir while it is being tore down. (go issue: https://github.com/golang/go/issues/43547) ``` === RUN TestFileStoreMsgBlkFailOnKernelFaultLostDataReporting/AES-GCM-S2 filestore_test.go:5195: ------------> 128 testing.go:1225: TempDir RemoveAll cleanup: unlinkat ./TestFileStoreMsgBlkFailOnKernelFaultLostDataReportingAES-GCM-S23605508670/001/msgs: directory not empty --- FAIL: TestFileStoreMsgBlkFailOnKernelFaultLostDataReporting (0.02s) ``` Signed-off-by: Waldemar Quevedo <wally@nats.io>
This commit is contained in:
@@ -50,6 +50,7 @@ func testFileStoreAllPermutations(t *testing.T, fn func(t *testing.T, fcfg FileS
|
||||
t.Run(subtestName, func(t *testing.T) {
|
||||
fcfg.StoreDir = t.TempDir()
|
||||
fn(t, fcfg)
|
||||
time.Sleep(100 * time.Millisecond)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user