aboutsummaryrefslogtreecommitdiffhomepage
path: root/common/para
diff options
context:
space:
mode:
authorCameron Moore <[email protected]>2020-12-17 11:31:40 -0600
committerBjørn Erik Pedersen <[email protected]>2020-12-17 22:19:17 +0100
commit8103188b9b9e8eeb3bcb53c8b64e2b83397e82ae (patch)
tree2cf0959870616226413d8828ecbc38fb3788e069 /common/para
parent3ba147e702a5ae0af6e8b3b0296d256c3246a546 (diff)
downloadhugo-8103188b9b9e8eeb3bcb53c8b64e2b83397e82ae.tar.gz
hugo-8103188b9b9e8eeb3bcb53c8b64e2b83397e82ae.zip
para: Show more detail on failed time test
Give us more visibility into how badly a given host is failing in the time test. Updates #6963
Diffstat (limited to 'common/para')
-rw-r--r--common/para/para_test.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/common/para/para_test.go b/common/para/para_test.go
index e89f9360b..627528cf9 100644
--- a/common/para/para_test.go
+++ b/common/para/para_test.go
@@ -81,6 +81,9 @@ func TestPara(t *testing.T) {
c.Assert(r.Wait(), qt.IsNil)
c.Assert(counter, qt.Equals, int64(n))
- c.Assert(time.Since(start) < n/2*time.Millisecond, qt.Equals, true)
+
+ since := time.Since(start)
+ limit := n / 2 * time.Millisecond
+ c.Assert(since < limit, qt.Equals, true, qt.Commentf("%s >= %s", since, limit))
})
}