1
0
mirror of https://github.com/taigrr/bitcask synced 2025-01-18 04:03:17 -08:00

tests: fix wg race (#150)

Signed-off-by: Ignacio Hagopian <jsign.uy@gmail.com>
This commit is contained in:
Ignacio Hagopian
2020-04-19 22:05:07 -03:00
committed by GitHub
parent f943c07b1d
commit 17e96a1a45

View File

@@ -1105,11 +1105,11 @@ func TestConcurrent(t *testing.T) {
}
wg := &sync.WaitGroup{}
wg.Add(3)
go f(wg, 2)
go f(wg, 3)
go f(wg, 5)
wg.Add(3)
wg.Wait()
})
@@ -1127,11 +1127,10 @@ func TestConcurrent(t *testing.T) {
}
wg := &sync.WaitGroup{}
go f(wg, 100)
go f(wg, 100)
go f(wg, 100)
wg.Add(3)
go f(wg, 100)
go f(wg, 100)
go f(wg, 100)
wg.Wait()
})