Skip to content

Commit

Permalink
fix: results report exited unexpectedly before the parallel process e…
Browse files Browse the repository at this point in the history
…nded

Signed-off-by: ty-dc <[email protected]>
  • Loading branch information
ty-dc committed Jul 11, 2023
1 parent af544dc commit 6c2c611
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pkg/lock/lock_debug_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ var _ = Describe("Debug lock", Label("unitest", "lock_test"), func() {

It("holds the lock timeout", func() {
go func() {
defer GinkgoRecover()

mutex.Lock()
time.Sleep(selfishTimeout)
mutex.Unlock()
Expand All @@ -50,6 +52,8 @@ var _ = Describe("Debug lock", Label("unitest", "lock_test"), func() {

It("ignores the timeout when unlocking", func() {
go func() {
defer GinkgoRecover()

mutex.Lock()
time.Sleep(selfishTimeout)
mutex.UnlockIgnoreTime()
Expand All @@ -76,6 +80,8 @@ var _ = Describe("Debug lock", Label("unitest", "lock_test"), func() {

It("holds the lock timeout", func() {
go func() {
defer GinkgoRecover()

rwMutex.Lock()
time.Sleep(selfishTimeout)
rwMutex.Unlock()
Expand All @@ -86,6 +92,8 @@ var _ = Describe("Debug lock", Label("unitest", "lock_test"), func() {

It("ignores the timeout when unlocking", func() {
go func() {
defer GinkgoRecover()

rwMutex.Lock()
time.Sleep(selfishTimeout)
rwMutex.UnlockIgnoreTime()
Expand Down

0 comments on commit 6c2c611

Please sign in to comment.