Commit 71b9f3fd authored by Kirill Smelkov's avatar Kirill Smelkov

tracing/tracetest: Mark T failed on fatalfInNonMain

There is no guaranty that the main thread would call Fatal or Fail if a
non-main thread calls fatalfInNonMain. This way it was possible for a
test to succeed if only non-main thread(s) failed somehow.

-> Fix it by marking the test as failed if any non-main thread fails.
parent e292c06f
...@@ -512,5 +512,6 @@ func (t *T) fatalfInNonMain(format string, argv ...interface{}) { ...@@ -512,5 +512,6 @@ func (t *T) fatalfInNonMain(format string, argv ...interface{}) {
t.Logf(format, argv...) t.Logf(format, argv...)
t.Logf("%s\n", debug.Stack()) t.Logf("%s\n", debug.Stack())
t.Fail()
runtime.Goexit() runtime.Goexit()
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment