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
commit 2034a52186eb0c2860f43319eae22e304f93e8d0 Author: Gary D. Gregory <garydgreg...@gmail.com> AuthorDate: Mon Aug 25 16:19:38 2025 -0400 Sort annotations Fewer magic strings. --- .../java/org/apache/commons/lang3/time/DateUtilsTest.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/test/java/org/apache/commons/lang3/time/DateUtilsTest.java b/src/test/java/org/apache/commons/lang3/time/DateUtilsTest.java index b6ac4b232..379f4918b 100644 --- a/src/test/java/org/apache/commons/lang3/time/DateUtilsTest.java +++ b/src/test/java/org/apache/commons/lang3/time/DateUtilsTest.java @@ -1321,7 +1321,7 @@ void testToCalendarWithTimeZoneNull() { @ParameterizedTest @MethodSource("testToLocalDateTimeTimeZone") @DefaultLocale(language = "en", country = "US") - @DefaultTimeZone("GMT") + @DefaultTimeZone(TimeZones.GMT_ID) void testToLocalDateTime(final LocalDateTime expected, final Date date, final TimeZone timeZone) { assertEquals(LocalDateTime.ofInstant(date.toInstant(), ZoneId.systemDefault()), DateUtils.toLocalDateTime(date), () -> String.format("expected = %s, date = %s, timeZone = %s, TimeZone.getDefault() = %s", expected, date, timeZone, TimeZone.getDefault())); @@ -1330,7 +1330,7 @@ void testToLocalDateTime(final LocalDateTime expected, final Date date, final Ti @ParameterizedTest @MethodSource("testToLocalDateTimeTimeZone") @DefaultLocale(language = "en", country = "US") - @DefaultTimeZone("GMT") + @DefaultTimeZone(TimeZones.GMT_ID) void testToLocalDateTimeTimeZone(final LocalDateTime expected, final Date date, final TimeZone timeZone) { assertEquals(expected, DateUtils.toLocalDateTime(date, timeZone), () -> String.format("expected = %s, date = %s, timeZone = %s, TimeZone.getDefault() = %s", expected, date, timeZone, TimeZone.getDefault())); @@ -1339,7 +1339,7 @@ void testToLocalDateTimeTimeZone(final LocalDateTime expected, final Date date, @ParameterizedTest @MethodSource("testToLocalDateTimeTimeZone") @DefaultLocale(language = "en", country = "US") - @DefaultTimeZone("GMT") + @DefaultTimeZone(TimeZones.GMT_ID) void testToOffsetDateTime(final LocalDateTime expected, final Date date, final TimeZone timeZone) { final OffsetDateTime offsetDateTime = DateUtils.toOffsetDateTime(date); assertEquals(OffsetDateTime.ofInstant(date.toInstant(), ZoneId.systemDefault()), offsetDateTime, @@ -1349,7 +1349,7 @@ void testToOffsetDateTime(final LocalDateTime expected, final Date date, final T @ParameterizedTest @MethodSource("testToLocalDateTimeTimeZone") @DefaultLocale(language = "en", country = "US") - @DefaultTimeZone("GMT") + @DefaultTimeZone(TimeZones.GMT_ID) void testToOffsetDateTimeTimeZone(final LocalDateTime expected, final Date date, final TimeZone timeZone) { assertEquals(expected, DateUtils.toOffsetDateTime(date, timeZone).toLocalDateTime(), () -> String.format("expected = %s, date = %s, timeZone = %s, TimeZone.getDefault() = %s", expected, date, timeZone, TimeZone.getDefault())); @@ -1358,7 +1358,7 @@ void testToOffsetDateTimeTimeZone(final LocalDateTime expected, final Date date, @ParameterizedTest @MethodSource("testToLocalDateTimeTimeZone") @DefaultLocale(language = "en", country = "US") - @DefaultTimeZone("GMT") + @DefaultTimeZone(TimeZones.GMT_ID) void testToZonedDateTime(final LocalDateTime expected, final Date date, final TimeZone timeZone) { final ZonedDateTime zonedDateTime = DateUtils.toZonedDateTime(date); assertEquals(ZonedDateTime.ofInstant(date.toInstant(), ZoneId.systemDefault()), zonedDateTime, @@ -1369,9 +1369,9 @@ void testToZonedDateTime(final LocalDateTime expected, final Date date, final Ti } @ParameterizedTest - @DefaultLocale(language = "en", country = "US") @MethodSource("testToLocalDateTimeTimeZone") - @DefaultTimeZone("GMT") + @DefaultLocale(language = "en", country = "US") + @DefaultTimeZone(TimeZones.GMT_ID) void testToZonedDateTimeTimeZone(final LocalDateTime expected, final Date date, final TimeZone timeZone) { final ZonedDateTime zonedDateTime = DateUtils.toZonedDateTime(date, timeZone); assertEquals(expected, zonedDateTime.toOffsetDateTime().toLocalDateTime(),