-
Notifications
You must be signed in to change notification settings - Fork 18.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Properly fix "daemon kill" on test failure #10086
Properly fix "daemon kill" on test failure #10086
Conversation
Wait! This can be even slightly simpler. |
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
6066b59
to
c18fdc3
Compare
Updated! |
I figured we were hiding an issue with the previous fix. 👍 So, to unwrap this a little, when we had a failure before, it wasn't running We fix it by actually capturing the failure when it happens (in an |
|
Here's my testing notes: $ cat integration-cli/fail_test.go
package main
import "testing"
func TestFail(t *testing.T) {
t.Fatal("lolol")
}
$ make TESTFLAGS='-test.run TestFail' test-integration-cli
...
< hangs >
^C
$ # apply PR
$ make TESTFLAGS='-test.run TestFail' test-integration-cli
...
+ go test -test.run TestFail -test.timeout=30m github.com/docker/docker/integration-cli
--- FAIL: TestFail (0.00s)
fail_test.go:6: lolol
FAIL
coverage: 1.0% of statements
exit status 1
FAIL github.com/docker/docker/integration-cli 0.007s
++++ cat /go/src/github.com/docker/docker/bundles/1.4.1-dev/test-integration-cli/docker.pid
+++ kill 454
Makefile:71: recipe for target 'test-integration-cli' failed
make: *** [test-integration-cli] Error 1
$ |
I tested locally, all okay, but I still want to see what drone think about all this. |
Drone is okay with this - LGTM |
LGTM |
…lure Properly fix "daemon kill" on test failure
Fixes #10074