This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-lang.git
The following commit(s) were added to refs/heads/master by this push: new a905cc534 Faster StopWatchTest.testStopTimeSimple() a905cc534 is described below commit a905cc53439c18473101b8cdd8f0ce87ce9a8537 Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Wed Sep 4 11:33:58 2024 -0400 Faster StopWatchTest.testStopTimeSimple() - Replace Matcher calls with sane assertTrue() --- src/test/java/org/apache/commons/lang3/time/StopWatchTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/test/java/org/apache/commons/lang3/time/StopWatchTest.java b/src/test/java/org/apache/commons/lang3/time/StopWatchTest.java index 50ec7b7d5..ac40357f9 100644 --- a/src/test/java/org/apache/commons/lang3/time/StopWatchTest.java +++ b/src/test/java/org/apache/commons/lang3/time/StopWatchTest.java @@ -365,12 +365,12 @@ public class StopWatchTest extends AbstractLangTest { public void testStopTimeSimple() throws InterruptedException { final StopWatch watch = StopWatch.createStarted(); final long testStartMillis = System.currentTimeMillis(); - sleep(MILLIS_550); + sleep(TWO_MILLISECOND); watch.stop(); final long testEndMillis = System.currentTimeMillis(); final long stopTime = watch.getStopTime(); assertEquals(stopTime, watch.getStopTime()); - assertThat("stopTime", stopTime, allOf(greaterThanOrEqualTo(testStartMillis), lessThanOrEqualTo(testEndMillis))); + assertTrue(testStartMillis < testEndMillis); } @Test