From 5eb30b61bbcb23fe32a0803573e3b0d4581ce972 Mon Sep 17 00:00:00 2001 From: Lachlan Roberts Date: Tue, 21 Sep 2021 09:33:13 +1000 Subject: [PATCH] Issue #6100 - fix flaky test MavenMetadataTest Signed-off-by: Lachlan Roberts --- .../org/eclipse/jetty/start/fileinits/MavenMetadataTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jetty-start/src/test/java/org/eclipse/jetty/start/fileinits/MavenMetadataTest.java b/jetty-start/src/test/java/org/eclipse/jetty/start/fileinits/MavenMetadataTest.java index 7bb9c8b3e72..068022c9e14 100644 --- a/jetty-start/src/test/java/org/eclipse/jetty/start/fileinits/MavenMetadataTest.java +++ b/jetty-start/src/test/java/org/eclipse/jetty/start/fileinits/MavenMetadataTest.java @@ -79,7 +79,7 @@ public class MavenMetadataTest @Test public void testIsExpiredTimestampYesterday() { - LocalDateTime yesterday = LocalDateTime.now().minusDays(1); + LocalDateTime yesterday = LocalDateTime.now(ZoneId.of("UTC")).minusDays(1); String timestamp = getTimestampFormatter().format(yesterday); assertTrue(MavenMetadata.isExpiredTimestamp(timestamp), "Timestamp should be stale: " + timestamp); }