mirror of
https://github.com/apache/commons-lang.git
synced 2025-02-06 18:18:22 +00:00
EventCountCircuitBreakerTest#testNow: improve assertion failure message
(side-effects: close #298, close #297, close #279, close #184, close #75)
This commit is contained in:
parent
7a3ca8598d
commit
758228f691
@ -100,7 +100,7 @@ public void testNow() {
|
|||||||
TimeUnit.SECONDS);
|
TimeUnit.SECONDS);
|
||||||
final long now = breaker.now();
|
final long now = breaker.now();
|
||||||
final long delta = Math.abs(System.nanoTime() - now);
|
final long delta = Math.abs(System.nanoTime() - now);
|
||||||
assertTrue("Delta to current time too large", delta < 100000);
|
assertTrue(String.format("Delta %d ns to current time too large", delta), delta < 100000);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user