From 593d546946b6897654bfb5b53b1241674b77d343 Mon Sep 17 00:00:00 2001 From: Victor Marmol Date: Tue, 27 Jan 2015 13:51:32 -0800 Subject: [PATCH] Expect user + cpu to be within 500ms of total. This should be a sane default. --- integration/tests/api/test_utils.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/integration/tests/api/test_utils.go b/integration/tests/api/test_utils.go index b7ae79f7..684ab74c 100644 --- a/integration/tests/api/test_utils.go +++ b/integration/tests/api/test_utils.go @@ -46,7 +46,7 @@ func checkCpuStats(t *testing.T, stat info.CpuStats) { totalUsage += usage } inDelta(t, stat.Usage.Total, totalUsage, uint64((5 * time.Millisecond).Nanoseconds()), "Per-core CPU usage") - inDelta(t, stat.Usage.Total, stat.Usage.User+stat.Usage.System, uint64((25 * time.Millisecond).Nanoseconds()), "User + system CPU usage") + inDelta(t, stat.Usage.Total, stat.Usage.User+stat.Usage.System, uint64((500 * time.Millisecond).Nanoseconds()), "User + system CPU usage") assert.Equal(0, stat.Load, "Non-zero load is unexpected as it is currently unset. Do we need to update the test?") }