From 0749749a11c5abf851d085165f8a7112ebb4e110 Mon Sep 17 00:00:00 2001 From: Gary Gregory Date: Sat, 20 Jan 2024 10:35:42 -0500 Subject: [PATCH] Declutter: Tests don't need Javadoc @since tags --- .../commons/lang3/StringUtilsValueOfTest.java | 1 - ...lectionToStringBuilderConcurrencyTest.java | 1 - ...ngBuilderMutateInspectConcurrencyTest.java | 1 - .../builder/ToStringStyleConcurrencyTest.java | 1 - .../lang3/event/EventListenerSupportTest.java | 1 - .../commons/lang3/event/EventUtilsTest.java | 1 - .../lang3/exception/ExceptionUtilsTest.java | 1 - .../lang3/mutable/MutableBooleanTest.java | 1 - .../lang3/text/ExtendedMessageFormatTest.java | 1 - .../lang3/time/DateUtilsRoundingTest.java | 26 ------------------- .../lang3/time/FastDateFormatTest.java | 1 - .../time/FastDateFormat_PrinterTest.java | 1 - .../lang3/time/FastDateParserTest.java | 1 - .../lang3/time/FastDatePrinterTest.java | 1 - 14 files changed, 39 deletions(-) diff --git a/src/test/java/org/apache/commons/lang3/StringUtilsValueOfTest.java b/src/test/java/org/apache/commons/lang3/StringUtilsValueOfTest.java index 1f7dd7af8..119d19449 100644 --- a/src/test/java/org/apache/commons/lang3/StringUtilsValueOfTest.java +++ b/src/test/java/org/apache/commons/lang3/StringUtilsValueOfTest.java @@ -22,7 +22,6 @@ import org.junit.jupiter.api.Test; /** * Tests {@link StringUtils}'s valueOf() methods. * - * @since 3.9 */ public class StringUtilsValueOfTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderConcurrencyTest.java b/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderConcurrencyTest.java index 372e4e6f4..cb41d3e58 100644 --- a/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderConcurrencyTest.java +++ b/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderConcurrencyTest.java @@ -48,7 +48,6 @@ import org.junit.jupiter.api.Test; * * @see [LANG-762] Handle or document ReflectionToStringBuilder * and ToStringBuilder for collections that are not thread safe - * @since 3.1 */ public class ReflectionToStringBuilderConcurrencyTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderMutateInspectConcurrencyTest.java b/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderMutateInspectConcurrencyTest.java index ec4d9e0b9..544f1af7c 100644 --- a/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderMutateInspectConcurrencyTest.java +++ b/src/test/java/org/apache/commons/lang3/builder/ReflectionToStringBuilderMutateInspectConcurrencyTest.java @@ -33,7 +33,6 @@ import org.junit.jupiter.api.Test; * * @see [LANG-762] Handle or document ReflectionToStringBuilder * and ToStringBuilder for collections that are not thread safe - * @since 3.1 */ public class ReflectionToStringBuilderMutateInspectConcurrencyTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/builder/ToStringStyleConcurrencyTest.java b/src/test/java/org/apache/commons/lang3/builder/ToStringStyleConcurrencyTest.java index 92a6bcab1..86fb32db3 100644 --- a/src/test/java/org/apache/commons/lang3/builder/ToStringStyleConcurrencyTest.java +++ b/src/test/java/org/apache/commons/lang3/builder/ToStringStyleConcurrencyTest.java @@ -44,7 +44,6 @@ import org.junit.jupiter.api.Test; * * @see [LANG-762] Handle or document ReflectionToStringBuilder * and ToStringBuilder for collections that are not thread safe - * @since 3.1 */ public class ToStringStyleConcurrencyTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/event/EventListenerSupportTest.java b/src/test/java/org/apache/commons/lang3/event/EventListenerSupportTest.java index 5c6a38083..8ffa545c5 100644 --- a/src/test/java/org/apache/commons/lang3/event/EventListenerSupportTest.java +++ b/src/test/java/org/apache/commons/lang3/event/EventListenerSupportTest.java @@ -41,7 +41,6 @@ import org.easymock.EasyMock; import org.junit.jupiter.api.Test; /** - * @since 3.0 */ public class EventListenerSupportTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/event/EventUtilsTest.java b/src/test/java/org/apache/commons/lang3/event/EventUtilsTest.java index edbf73c3c..defdbf924 100644 --- a/src/test/java/org/apache/commons/lang3/event/EventUtilsTest.java +++ b/src/test/java/org/apache/commons/lang3/event/EventUtilsTest.java @@ -40,7 +40,6 @@ import org.apache.commons.lang3.AbstractLangTest; import org.junit.jupiter.api.Test; /** - * @since 3.0 */ public class EventUtilsTest extends AbstractLangTest { public static class EventCounter { diff --git a/src/test/java/org/apache/commons/lang3/exception/ExceptionUtilsTest.java b/src/test/java/org/apache/commons/lang3/exception/ExceptionUtilsTest.java index a18ff5a3d..e6815d4b7 100644 --- a/src/test/java/org/apache/commons/lang3/exception/ExceptionUtilsTest.java +++ b/src/test/java/org/apache/commons/lang3/exception/ExceptionUtilsTest.java @@ -47,7 +47,6 @@ import org.junit.jupiter.api.Test; /** * Tests {@link org.apache.commons.lang3.exception.ExceptionUtils}. * - * @since 1.0 */ public class ExceptionUtilsTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/mutable/MutableBooleanTest.java b/src/test/java/org/apache/commons/lang3/mutable/MutableBooleanTest.java index 1520fa7f2..9443bbb49 100644 --- a/src/test/java/org/apache/commons/lang3/mutable/MutableBooleanTest.java +++ b/src/test/java/org/apache/commons/lang3/mutable/MutableBooleanTest.java @@ -29,7 +29,6 @@ import org.junit.jupiter.api.Test; /** * JUnit tests. * - * @since 2.2 * @see MutableBoolean */ public class MutableBooleanTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/text/ExtendedMessageFormatTest.java b/src/test/java/org/apache/commons/lang3/text/ExtendedMessageFormatTest.java index 6fed994cb..ceb135622 100644 --- a/src/test/java/org/apache/commons/lang3/text/ExtendedMessageFormatTest.java +++ b/src/test/java/org/apache/commons/lang3/text/ExtendedMessageFormatTest.java @@ -40,7 +40,6 @@ import org.junit.jupiter.api.Test; /** * Test case for {@link ExtendedMessageFormat}. * - * @since 2.4 */ @Deprecated public class ExtendedMessageFormatTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/time/DateUtilsRoundingTest.java b/src/test/java/org/apache/commons/lang3/time/DateUtilsRoundingTest.java index 00b69bba7..ecb70645c 100644 --- a/src/test/java/org/apache/commons/lang3/time/DateUtilsRoundingTest.java +++ b/src/test/java/org/apache/commons/lang3/time/DateUtilsRoundingTest.java @@ -39,7 +39,6 @@ import org.junit.jupiter.api.Test; * A month with 29 or 30 days will be rounded up from the 16th * A month with 31 days will be rounded up from the 17th * - * @since 3.0 */ public class DateUtilsRoundingTest extends AbstractLangTest { @@ -68,7 +67,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * @param roundedDownDate the result if lastRoundDownDate was rounded with calendarField * @param lastRoundDownDate rounding this value with calendarField will result in roundedDownDate * @param calendarField a Calendar.field value - * @since 3.0 */ protected void baseRoundTest(final Date roundedUpDate, final Date roundedDownDate, final Date lastRoundDownDate, final int calendarField) { final Date firstRoundUpDate = DateUtils.addMilliseconds(lastRoundDownDate, 1); @@ -119,7 +117,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * @param truncatedDate expected Date when lastTruncateDate is truncated with calendarField * @param lastTruncateDate the last possible Date which will truncate to truncatedDate with calendarField * @param calendarField a Calendar.field value - * @since 3.0 */ protected void baseTruncateTest(final Date truncatedDate, final Date lastTruncateDate, final int calendarField) { final Date nextTruncateDate = DateUtils.addMilliseconds(lastTruncateDate, 1); @@ -162,7 +159,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * @param minDate the lower bound * @param maxDate the upper bound * @param calendarField a Calendar.field value - * @since 3.0 */ protected void roundToJanuaryFirst(final Date minDate, final Date maxDate, final int calendarField) { assertEquals(januaryOneDate, DateUtils.round(januaryOneDate, calendarField), "Rounding "+ fdf.format(januaryOneDate) +" as Date with CalendarField-value "+ calendarField +" must return itself"); @@ -216,7 +212,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundAmPm() throws Exception { @@ -249,7 +244,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundDate() throws Exception { @@ -277,7 +271,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundDayOfMonth() throws Exception { @@ -305,7 +298,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundHour() throws Exception { @@ -333,7 +325,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundHourOfDay() throws Exception { @@ -361,7 +352,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundMilliSecond() throws Exception { @@ -387,7 +377,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundMinute() throws Exception { @@ -415,7 +404,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundMonth() throws Exception { @@ -460,7 +448,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundSecond() throws Exception { @@ -488,7 +475,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes rounding to January 1 * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundSemiMonth() throws Exception { @@ -555,7 +541,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Tests DateUtils.round()-method with Calendar.Year * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testRoundYear() throws Exception { @@ -571,7 +556,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes truncating the extremes of both AM and PM of one day * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateAmPm() throws Exception { @@ -590,7 +574,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.DATE * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateDate() throws Exception { @@ -603,7 +586,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.DAY_OF_MONTH * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateDayOfMonth() throws Exception { @@ -616,7 +598,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.HOUR * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateHour() throws Exception { @@ -629,7 +610,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.HOUR_OF_DAY * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateHourOfDay() throws Exception { @@ -641,7 +621,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { /** * Test DateUtils.truncate()-method with Calendar.SECOND * - * @since 3.0 */ @Test public void testTruncateMilliSecond() { @@ -653,7 +632,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.MINUTE * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateMinute() throws Exception { @@ -666,7 +644,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.MONTH * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateMonth() throws Exception { @@ -680,7 +657,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.SECOND * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateSecond() throws Exception { @@ -694,7 +670,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Includes truncating months with 28, 29, 30 and 31 days, each with first and second half * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateSemiMonth() throws Exception { @@ -747,7 +722,6 @@ public class DateUtilsRoundingTest extends AbstractLangTest { * Test DateUtils.truncate()-method with Calendar.YEAR * * @throws Exception so we don't have to catch it - * @since 3.0 */ @Test public void testTruncateYear() throws Exception { diff --git a/src/test/java/org/apache/commons/lang3/time/FastDateFormatTest.java b/src/test/java/org/apache/commons/lang3/time/FastDateFormatTest.java index 4d9c46c7f..1b8961b6e 100644 --- a/src/test/java/org/apache/commons/lang3/time/FastDateFormatTest.java +++ b/src/test/java/org/apache/commons/lang3/time/FastDateFormatTest.java @@ -46,7 +46,6 @@ import org.junitpioneer.jupiter.DefaultTimeZone; /** * Unit tests {@link org.apache.commons.lang3.time.FastDateFormat}. * - * @since 2.0 */ public class FastDateFormatTest extends AbstractLangTest { private static final int NTHREADS = 10; diff --git a/src/test/java/org/apache/commons/lang3/time/FastDateFormat_PrinterTest.java b/src/test/java/org/apache/commons/lang3/time/FastDateFormat_PrinterTest.java index 6ab4e22cc..5b7e07a4e 100644 --- a/src/test/java/org/apache/commons/lang3/time/FastDateFormat_PrinterTest.java +++ b/src/test/java/org/apache/commons/lang3/time/FastDateFormat_PrinterTest.java @@ -22,7 +22,6 @@ import java.util.TimeZone; /** * Unit tests for the print methods of FastDateFormat * - * @since 3.2 */ public class FastDateFormat_PrinterTest extends FastDatePrinterTest { diff --git a/src/test/java/org/apache/commons/lang3/time/FastDateParserTest.java b/src/test/java/org/apache/commons/lang3/time/FastDateParserTest.java index 6473982a6..430b8a3b0 100644 --- a/src/test/java/org/apache/commons/lang3/time/FastDateParserTest.java +++ b/src/test/java/org/apache/commons/lang3/time/FastDateParserTest.java @@ -50,7 +50,6 @@ import org.junit.jupiter.params.provider.MethodSource; /** * Unit tests {@link org.apache.commons.lang3.time.FastDateParser}. * - * @since 3.2 */ public class FastDateParserTest extends AbstractLangTest { diff --git a/src/test/java/org/apache/commons/lang3/time/FastDatePrinterTest.java b/src/test/java/org/apache/commons/lang3/time/FastDatePrinterTest.java index 8da22d4e2..e3cc4d0f5 100644 --- a/src/test/java/org/apache/commons/lang3/time/FastDatePrinterTest.java +++ b/src/test/java/org/apache/commons/lang3/time/FastDatePrinterTest.java @@ -39,7 +39,6 @@ import org.junitpioneer.jupiter.DefaultTimeZone; /** * Unit tests {@link org.apache.commons.lang3.time.FastDatePrinter}. * - * @since 3.0 */ public class FastDatePrinterTest extends AbstractLangTest {