Bug #8675
Updated by Tom Clegg about 8 years ago
Test succeeded on the third attempt, after two times failing like this:
<pre>
FAIL: logging_test.go:69: LoggingTestSuite.TestWriteMultipleLogs
logging_test.go:86:
c.Check(api.Content[0]["log"].(arvadosclient.Dict)["event_type"], Equals, "crunch-run")
... obtained string = "stdout"
... expected string = "crunch-run"
logging_test.go:87:
c.Check(api.Content[0]["log"].(arvadosclient.Dict)["properties"].(map[string]string)["text"], Equals, logtext1)
... obtained string = "" +
... "2015-12-29T15:51:45.000000002Z Doing stuff\n" +
... "2015-12-29T15:51:45.000000004Z Blurb\n"
... expected string = "" +
... "2015-12-29T15:51:45.000000001Z Hello world!\n" +
... "2015-12-29T15:51:45.000000003Z Goodbye\n"
logging_test.go:92:
c.Check(api.Content[1]["log"].(arvadosclient.Dict)["event_type"], Equals, "stdout")
... obtained string = "crunch-run"
... expected string = "stdout"
logging_test.go:93:
c.Check(api.Content[1]["log"].(arvadosclient.Dict)["properties"].(map[string]string)["text"], Equals, logtext2)
... obtained string = "" +
... "2015-12-29T15:51:45.000000001Z Hello world!\n" +
... "2015-12-29T15:51:45.000000003Z Goodbye\n"
... expected string = "" +
... "2015-12-29T15:51:45.000000002Z Doing stuff\n" +
... "2015-12-29T15:51:45.000000004Z Blurb\n"
</pre>
Presumably it doesn't matter which one is [0] and which is [1] as long as the content matches the event_type, and the test just needs to be fixed to accommodate both orders.