projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
19961: Fix races in tests.
[arvados.git]
/
lib
/
crunchrun
/
crunchrun_test.go
diff --git
a/lib/crunchrun/crunchrun_test.go
b/lib/crunchrun/crunchrun_test.go
index 1a00e9d52aed86cf3740ab2cc7f1995816997f1c..786f9410a8ac77783edc8e04652960ba56a1217e 100644
(file)
--- a/
lib/crunchrun/crunchrun_test.go
+++ b/
lib/crunchrun/crunchrun_test.go
@@
-1157,6
+1157,7
@@
func (s *TestSuite) TestStopOnSignal(c *C) {
s.executor.runFunc = func() int {
s.executor.created.Stdout.Write([]byte("foo\n"))
s.runner.SigChan <- syscall.SIGINT
s.executor.runFunc = func() int {
s.executor.created.Stdout.Write([]byte("foo\n"))
s.runner.SigChan <- syscall.SIGINT
+ time.Sleep(10 * time.Second)
return 0
}
s.testStopContainer(c)
return 0
}
s.testStopContainer(c)
@@
-1167,6
+1168,7
@@
func (s *TestSuite) TestStopOnArvMountDeath(c *C) {
s.executor.created.Stdout.Write([]byte("foo\n"))
s.runner.ArvMountExit <- nil
close(s.runner.ArvMountExit)
s.executor.created.Stdout.Write([]byte("foo\n"))
s.runner.ArvMountExit <- nil
close(s.runner.ArvMountExit)
+ time.Sleep(10 * time.Second)
return 0
}
s.runner.ArvMountExit = make(chan error)
return 0
}
s.runner.ArvMountExit = make(chan error)