From 82a30a32b7927378ca035737b1b328ca7c9185e3 Mon Sep 17 00:00:00 2001 From: Yegor Bugayenko Date: Fri, 12 Aug 2022 07:45:54 +0300 Subject: [PATCH] #1649 MagicNumberCheck removed --- pom.xml | 2 +- src/main/java/org/cactoos/bytes/DigestEnvelope.java | 1 - src/main/java/org/cactoos/bytes/HexOf.java | 1 - src/main/java/org/cactoos/bytes/InputAsBytes.java | 1 - src/main/java/org/cactoos/bytes/Md5DigestOf.java | 1 - src/main/java/org/cactoos/bytes/ReaderAsBytes.java | 2 -- src/main/java/org/cactoos/bytes/Sha1DigestOf.java | 1 - src/main/java/org/cactoos/bytes/Sha256DigestOf.java | 1 - src/main/java/org/cactoos/func/Retry.java | 1 - src/main/java/org/cactoos/io/GzipInput.java | 1 - src/main/java/org/cactoos/io/GzipOutput.java | 1 - src/main/java/org/cactoos/io/TailOf.java | 1 - src/main/java/org/cactoos/io/TempFolder.java | 1 - src/main/java/org/cactoos/io/WriterAsOutput.java | 1 - src/main/java/org/cactoos/io/WriterAsOutputStream.java | 2 -- src/main/java/org/cactoos/iterable/IterableOf.java | 1 - src/main/java/org/cactoos/scalar/HashCode.java | 2 -- src/main/java/org/cactoos/scalar/LengthOf.java | 1 - src/main/java/org/cactoos/scalar/Retry.java | 1 - src/main/java/org/cactoos/text/HexOf.java | 1 - src/test/java/org/cactoos/bytes/BytesOfTest.java | 1 - src/test/java/org/cactoos/bytes/HexOfTest.java | 1 - src/test/java/org/cactoos/collection/ImmutableTest.java | 1 - src/test/java/org/cactoos/collection/NoNullsTest.java | 1 - src/test/java/org/cactoos/experimental/ThreadsTest.java | 1 - src/test/java/org/cactoos/func/ChainedTest.java | 1 - src/test/java/org/cactoos/func/FallbackFromTest.java | 1 - src/test/java/org/cactoos/func/RepeatedTest.java | 1 - src/test/java/org/cactoos/func/RetryTest.java | 1 - src/test/java/org/cactoos/io/DirectoryTest.java | 2 -- src/test/java/org/cactoos/io/HeadInputStreamTest.java | 1 - src/test/java/org/cactoos/io/HeadOfTest.java | 1 - src/test/java/org/cactoos/io/LoggingInputStreamTest.java | 5 ----- src/test/java/org/cactoos/io/LoggingInputTest.java | 2 -- src/test/java/org/cactoos/io/ResourceOfTest.java | 2 -- src/test/java/org/cactoos/io/SlowInputStreamTest.java | 1 - src/test/java/org/cactoos/io/StickyTest.java | 1 - src/test/java/org/cactoos/io/WriterAsOutputStreamTest.java | 3 --- src/test/java/org/cactoos/io/ZipTest.java | 1 - src/test/java/org/cactoos/iterable/CycledTest.java | 1 - src/test/java/org/cactoos/iterable/FilteredTest.java | 2 -- src/test/java/org/cactoos/iterable/IterableOfTest.java | 2 -- src/test/java/org/cactoos/iterable/JoinedTest.java | 1 - src/test/java/org/cactoos/iterable/MappedTest.java | 1 - src/test/java/org/cactoos/iterable/MappedWithIndexTest.java | 1 - src/test/java/org/cactoos/iterable/MatchedTest.java | 1 - src/test/java/org/cactoos/iterable/PartitionedTest.java | 1 - src/test/java/org/cactoos/iterable/RangeOfTest.java | 1 - src/test/java/org/cactoos/iterable/RepeatedTest.java | 1 - src/test/java/org/cactoos/iterable/ReversedTest.java | 1 - src/test/java/org/cactoos/iterable/ShuffledTest.java | 1 - src/test/java/org/cactoos/iterable/SlicedTest.java | 1 - src/test/java/org/cactoos/iterable/SolidTest.java | 1 - src/test/java/org/cactoos/iterable/SortedTest.java | 1 - src/test/java/org/cactoos/iterable/SyncedTest.java | 1 - src/test/java/org/cactoos/iterable/TailOfTest.java | 1 - src/test/java/org/cactoos/iterator/CycledTest.java | 1 - src/test/java/org/cactoos/iterator/HeadOfTest.java | 1 - src/test/java/org/cactoos/iterator/JoinedTest.java | 1 - src/test/java/org/cactoos/iterator/MatchedTest.java | 1 - src/test/java/org/cactoos/iterator/PagedTest.java | 1 - src/test/java/org/cactoos/iterator/PartitionedTest.java | 1 - src/test/java/org/cactoos/iterator/RangeOfTest.java | 1 - src/test/java/org/cactoos/iterator/ReversedTest.java | 1 - src/test/java/org/cactoos/iterator/SlicedTest.java | 1 - src/test/java/org/cactoos/iterator/SyncedTest.java | 1 - src/test/java/org/cactoos/iterator/TailOfTest.java | 1 - .../java/org/cactoos/list/ImmutableListIteratorTest.java | 1 - src/test/java/org/cactoos/list/ImmutableTest.java | 1 - src/test/java/org/cactoos/list/JoinedListIteratorTest.java | 1 - src/test/java/org/cactoos/list/JoinedTest.java | 1 - src/test/java/org/cactoos/list/ListEnvelopeTest.java | 1 - .../java/org/cactoos/list/ListIteratorEnvelopeTest.java | 1 - src/test/java/org/cactoos/list/ListIteratorNoNullsTest.java | 1 - src/test/java/org/cactoos/list/ListOfTest.java | 3 --- src/test/java/org/cactoos/list/NoNullsTest.java | 1 - src/test/java/org/cactoos/map/GroupedTest.java | 3 --- src/test/java/org/cactoos/map/MapEntryTest.java | 1 - src/test/java/org/cactoos/number/AvgOfTest.java | 1 - src/test/java/org/cactoos/number/DivisionOfTest.java | 1 - src/test/java/org/cactoos/number/MaxOfTest.java | 1 - src/test/java/org/cactoos/number/MinOfTest.java | 1 - src/test/java/org/cactoos/number/MultiplicationOfTest.java | 1 - src/test/java/org/cactoos/number/NumberEnvelopeTest.java | 1 - src/test/java/org/cactoos/number/NumberOfScalarsTest.java | 1 - src/test/java/org/cactoos/number/NumberOfTest.java | 1 - src/test/java/org/cactoos/number/SumOfTest.java | 1 - src/test/java/org/cactoos/proc/ForEachTest.java | 1 - src/test/java/org/cactoos/proc/RepeatedProcTest.java | 1 - src/test/java/org/cactoos/scalar/AndTest.java | 1 - src/test/java/org/cactoos/scalar/EqualityTest.java | 1 - src/test/java/org/cactoos/scalar/FirstOfTest.java | 1 - src/test/java/org/cactoos/scalar/FoldedTest.java | 1 - src/test/java/org/cactoos/scalar/HighestOfTest.java | 1 - src/test/java/org/cactoos/scalar/ItemAtTest.java | 6 ------ src/test/java/org/cactoos/scalar/LengthOfTest.java | 1 - src/test/java/org/cactoos/scalar/LowestOfTest.java | 1 - src/test/java/org/cactoos/scalar/OrTest.java | 1 - src/test/java/org/cactoos/scalar/RepeatedTest.java | 1 - src/test/java/org/cactoos/scalar/RetryTest.java | 6 ------ src/test/java/org/cactoos/scalar/TernaryTest.java | 1 - src/test/java/org/cactoos/set/SetOfTest.java | 1 - src/test/java/org/cactoos/set/SortedTest.java | 1 - src/test/java/org/cactoos/text/AbbreviatedTest.java | 1 - src/test/java/org/cactoos/text/ComparableTextTest.java | 1 - src/test/java/org/cactoos/text/FormattedTextTest.java | 1 - src/test/java/org/cactoos/text/RandomizedTest.java | 1 - src/test/java/org/cactoos/text/RepeatedTest.java | 2 -- src/test/java/org/cactoos/text/ReplacedTest.java | 1 - src/test/java/org/cactoos/text/StrictTest.java | 1 - src/test/java/org/cactoos/text/SubTest.java | 1 - src/test/java/org/cactoos/text/TextOfDateTimeTest.java | 1 - src/test/java/org/cactoos/text/TextOfTest.java | 1 - src/test/java/org/cactoos/time/DateOfTest.java | 1 - src/test/java/org/cactoos/time/LocalDateTimeOfTest.java | 1 - src/test/java/org/cactoos/time/OffsetDateTimeOfTest.java | 1 - src/test/java/org/cactoos/time/ZonedDateTimeOfTest.java | 1 - 117 files changed, 1 insertion(+), 146 deletions(-) diff --git a/pom.xml b/pom.xml index 3dc2023f4..a30c7c837 100644 --- a/pom.xml +++ b/pom.xml @@ -250,7 +250,7 @@ SOFTWARE. com.qulice qulice-maven-plugin - 0.21.0 + 0.21.1 checkstyle:/src/site/resources/.* diff --git a/src/main/java/org/cactoos/bytes/DigestEnvelope.java b/src/main/java/org/cactoos/bytes/DigestEnvelope.java index a82f764ee..dcf07d21e 100644 --- a/src/main/java/org/cactoos/bytes/DigestEnvelope.java +++ b/src/main/java/org/cactoos/bytes/DigestEnvelope.java @@ -63,7 +63,6 @@ public abstract class DigestEnvelope implements Bytes { * @param algrthm The algorithm */ public DigestEnvelope(final Input input, final String algrthm) { - // @checkstyle MagicNumber (1 line) this(input, 16 << 10, algrthm); } diff --git a/src/main/java/org/cactoos/bytes/HexOf.java b/src/main/java/org/cactoos/bytes/HexOf.java index 1386eebe2..2a815f189 100644 --- a/src/main/java/org/cactoos/bytes/HexOf.java +++ b/src/main/java/org/cactoos/bytes/HexOf.java @@ -36,7 +36,6 @@ * Decodes origin {@link Text} using the hexadecimal encoding scheme. * * @since 0.30 - * @checkstyle MagicNumberCheck (500 lines) */ public final class HexOf implements Bytes { /** diff --git a/src/main/java/org/cactoos/bytes/InputAsBytes.java b/src/main/java/org/cactoos/bytes/InputAsBytes.java index 247208603..55fc5eece 100644 --- a/src/main/java/org/cactoos/bytes/InputAsBytes.java +++ b/src/main/java/org/cactoos/bytes/InputAsBytes.java @@ -55,7 +55,6 @@ public final class InputAsBytes implements Bytes { * @param input The input */ InputAsBytes(final Input input) { - // @checkstyle MagicNumber (1 line) this(input, 16 << 10); } diff --git a/src/main/java/org/cactoos/bytes/Md5DigestOf.java b/src/main/java/org/cactoos/bytes/Md5DigestOf.java index 5607da869..df31d1f82 100644 --- a/src/main/java/org/cactoos/bytes/Md5DigestOf.java +++ b/src/main/java/org/cactoos/bytes/Md5DigestOf.java @@ -48,7 +48,6 @@ public Md5DigestOf(final Input input) { * @param max Buffer size */ public Md5DigestOf(final Input input, final int max) { - // @checkstyle MagicNumber (1 line) super(input, max, "MD5"); } } diff --git a/src/main/java/org/cactoos/bytes/ReaderAsBytes.java b/src/main/java/org/cactoos/bytes/ReaderAsBytes.java index d391a14a2..9650b9371 100644 --- a/src/main/java/org/cactoos/bytes/ReaderAsBytes.java +++ b/src/main/java/org/cactoos/bytes/ReaderAsBytes.java @@ -70,7 +70,6 @@ final class ReaderAsBytes implements Bytes { * @param cset Charset */ ReaderAsBytes(final Reader rdr, final Charset cset) { - // @checkstyle MagicNumber (1 line) this(rdr, cset, 16 << 10); } @@ -82,7 +81,6 @@ final class ReaderAsBytes implements Bytes { * @since 0.13.2 */ ReaderAsBytes(final Reader rdr, final CharSequence cset) { - // @checkstyle MagicNumber (1 line) this(rdr, cset, 16 << 10); } diff --git a/src/main/java/org/cactoos/bytes/Sha1DigestOf.java b/src/main/java/org/cactoos/bytes/Sha1DigestOf.java index fe6eb9f56..62437c9ab 100644 --- a/src/main/java/org/cactoos/bytes/Sha1DigestOf.java +++ b/src/main/java/org/cactoos/bytes/Sha1DigestOf.java @@ -48,7 +48,6 @@ public Sha1DigestOf(final Input input) { * @param max Buffer size */ public Sha1DigestOf(final Input input, final int max) { - // @checkstyle MagicNumber (1 line) super(input, max, "SHA-1"); } } diff --git a/src/main/java/org/cactoos/bytes/Sha256DigestOf.java b/src/main/java/org/cactoos/bytes/Sha256DigestOf.java index 8d71795e5..4f42d9d65 100644 --- a/src/main/java/org/cactoos/bytes/Sha256DigestOf.java +++ b/src/main/java/org/cactoos/bytes/Sha256DigestOf.java @@ -48,7 +48,6 @@ public Sha256DigestOf(final Input input) { * @param max Buffer size */ public Sha256DigestOf(final Input input, final int max) { - // @checkstyle MagicNumber (1 line) super(input, max, "SHA-256"); } } diff --git a/src/main/java/org/cactoos/func/Retry.java b/src/main/java/org/cactoos/func/Retry.java index 049899e65..cc52641f3 100644 --- a/src/main/java/org/cactoos/func/Retry.java +++ b/src/main/java/org/cactoos/func/Retry.java @@ -57,7 +57,6 @@ public final class Retry implements Func { * @param fnc Func original */ public Retry(final Func fnc) { - // @checkstyle MagicNumberCheck (1 line) this(fnc, 3); } diff --git a/src/main/java/org/cactoos/io/GzipInput.java b/src/main/java/org/cactoos/io/GzipInput.java index 8064743b8..1a57b754f 100644 --- a/src/main/java/org/cactoos/io/GzipInput.java +++ b/src/main/java/org/cactoos/io/GzipInput.java @@ -50,7 +50,6 @@ public final class GzipInput implements Input { * @param input The input. */ public GzipInput(final Input input) { - // @checkstyle MagicNumberCheck (1 line) this(input, 16 << 10); } diff --git a/src/main/java/org/cactoos/io/GzipOutput.java b/src/main/java/org/cactoos/io/GzipOutput.java index 05803d57f..ca57bbc89 100644 --- a/src/main/java/org/cactoos/io/GzipOutput.java +++ b/src/main/java/org/cactoos/io/GzipOutput.java @@ -50,7 +50,6 @@ public final class GzipOutput implements Output { * @param output The output */ public GzipOutput(final Output output) { - // @checkstyle MagicNumberCheck (1 line) this(output, 16 << 10); } diff --git a/src/main/java/org/cactoos/io/TailOf.java b/src/main/java/org/cactoos/io/TailOf.java index bde377b49..ed507f544 100644 --- a/src/main/java/org/cactoos/io/TailOf.java +++ b/src/main/java/org/cactoos/io/TailOf.java @@ -59,7 +59,6 @@ public final class TailOf implements Input { * @param bytes Number of last bytes to show from input */ public TailOf(final Input inpt, final int bytes) { - // @checkstyle MagicNumber (1 line) this(inpt, bytes, 16384); } diff --git a/src/main/java/org/cactoos/io/TempFolder.java b/src/main/java/org/cactoos/io/TempFolder.java index 21af2ba2a..0204e64f0 100644 --- a/src/main/java/org/cactoos/io/TempFolder.java +++ b/src/main/java/org/cactoos/io/TempFolder.java @@ -78,7 +78,6 @@ public TempFolder() { new RangeOf<>('a', 'z', ch -> ++ch) ) ), - // @checkstyle MagicNumber (1 line) () -> 5 ) ) diff --git a/src/main/java/org/cactoos/io/WriterAsOutput.java b/src/main/java/org/cactoos/io/WriterAsOutput.java index a9dfcf269..6b63cd5fd 100644 --- a/src/main/java/org/cactoos/io/WriterAsOutput.java +++ b/src/main/java/org/cactoos/io/WriterAsOutput.java @@ -70,7 +70,6 @@ final class WriterAsOutput implements Output { * @param cset Charset */ WriterAsOutput(final Writer wtr, final Charset cset) { - // @checkstyle MagicNumber (1 line) this(wtr, cset, 16 << 10); } diff --git a/src/main/java/org/cactoos/io/WriterAsOutputStream.java b/src/main/java/org/cactoos/io/WriterAsOutputStream.java index 5c1023bc1..9c01418a9 100644 --- a/src/main/java/org/cactoos/io/WriterAsOutputStream.java +++ b/src/main/java/org/cactoos/io/WriterAsOutputStream.java @@ -80,7 +80,6 @@ final class WriterAsOutputStream extends OutputStream { * @param charset Charset */ WriterAsOutputStream(final Writer wtr, final CharSequence charset) { - // @checkstyle MagicNumber (1 line) this(wtr, charset, 16 << 10); } @@ -90,7 +89,6 @@ final class WriterAsOutputStream extends OutputStream { * @param charset Charset */ WriterAsOutputStream(final Writer wtr, final Charset charset) { - // @checkstyle MagicNumber (1 line) this(wtr, charset.name()); } diff --git a/src/main/java/org/cactoos/iterable/IterableOf.java b/src/main/java/org/cactoos/iterable/IterableOf.java index 33f201238..dd99f5f89 100644 --- a/src/main/java/org/cactoos/iterable/IterableOf.java +++ b/src/main/java/org/cactoos/iterable/IterableOf.java @@ -117,7 +117,6 @@ public boolean equals(final Object other) { ).value(); } - // @checkstyle MagicNumberCheck (30 lines) @Override public int hashCode() { return new Unchecked<>( diff --git a/src/main/java/org/cactoos/scalar/HashCode.java b/src/main/java/org/cactoos/scalar/HashCode.java index d2b2bba33..106985225 100644 --- a/src/main/java/org/cactoos/scalar/HashCode.java +++ b/src/main/java/org/cactoos/scalar/HashCode.java @@ -68,7 +68,6 @@ public final class HashCode implements Scalar { *

The {@code initial} and {@code multiplier} values are arbitrarily * set to 17 and 31 respectively. * @param attributes The object's attributes - * @checkstyle MagicNumber (3 lines) */ public HashCode(final Object... attributes) { this(new IterableOf<>(attributes)); @@ -80,7 +79,6 @@ public HashCode(final Object... attributes) { *

The {@code initial} and {@code multiplier} values are arbitrarily * set to 17 and 31 respectively. * @param attributes The object's attributes - * @checkstyle MagicNumber (3 lines) */ public HashCode(final Iterable attributes) { this(17, 31, attributes); diff --git a/src/main/java/org/cactoos/scalar/LengthOf.java b/src/main/java/org/cactoos/scalar/LengthOf.java index f7e24d2c3..48c539191 100644 --- a/src/main/java/org/cactoos/scalar/LengthOf.java +++ b/src/main/java/org/cactoos/scalar/LengthOf.java @@ -71,7 +71,6 @@ public LengthOf(final Text text) { * @param input The input */ public LengthOf(final Input input) { - // @checkstyle MagicNumber (1 line) this(input, 16 << 10); } diff --git a/src/main/java/org/cactoos/scalar/Retry.java b/src/main/java/org/cactoos/scalar/Retry.java index c0eeba9df..ed3582718 100644 --- a/src/main/java/org/cactoos/scalar/Retry.java +++ b/src/main/java/org/cactoos/scalar/Retry.java @@ -84,7 +84,6 @@ public Retry(final Scalar scalar) { * @param wait The {@link Duration} to wait between attempts */ public Retry(final Scalar scalar, final Duration wait) { - // @checkstyle MagicNumberCheck (1 line) this(scalar, 3, wait); } diff --git a/src/main/java/org/cactoos/text/HexOf.java b/src/main/java/org/cactoos/text/HexOf.java index 1423831e3..f6554a048 100644 --- a/src/main/java/org/cactoos/text/HexOf.java +++ b/src/main/java/org/cactoos/text/HexOf.java @@ -54,7 +54,6 @@ public HexOf(final Bytes bytes) { final char[] hex = new char[bts.length * 2]; int chr = -1; for (int idx = 0; idx < bts.length; ++idx) { - // @checkstyle MagicNumber (3 line) final int value = 0xff & bts[idx]; hex[++chr] = HexOf.HEX_CHARS[value >>> 4]; hex[++chr] = HexOf.HEX_CHARS[value & 0x0f]; diff --git a/src/test/java/org/cactoos/bytes/BytesOfTest.java b/src/test/java/org/cactoos/bytes/BytesOfTest.java index 3e0f69d59..1cb4ff0c9 100644 --- a/src/test/java/org/cactoos/bytes/BytesOfTest.java +++ b/src/test/java/org/cactoos/bytes/BytesOfTest.java @@ -105,7 +105,6 @@ void readsFromReader() throws Exception { new BytesOf( new StringReader(source), StandardCharsets.UTF_8, - // @checkstyle MagicNumberCheck (1 line) 16 << 10 ) ) diff --git a/src/test/java/org/cactoos/bytes/HexOfTest.java b/src/test/java/org/cactoos/bytes/HexOfTest.java index 2ff5f6106..2764c4280 100644 --- a/src/test/java/org/cactoos/bytes/HexOfTest.java +++ b/src/test/java/org/cactoos/bytes/HexOfTest.java @@ -36,7 +36,6 @@ * Test case for {@link HexOf}. * * @since 0.29 - * @checkstyle MagicNumberCheck (500 line) * @checkstyle JavadocMethodCheck (500 line) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ diff --git a/src/test/java/org/cactoos/collection/ImmutableTest.java b/src/test/java/org/cactoos/collection/ImmutableTest.java index d33e6b304..7648280bb 100644 --- a/src/test/java/org/cactoos/collection/ImmutableTest.java +++ b/src/test/java/org/cactoos/collection/ImmutableTest.java @@ -34,7 +34,6 @@ * Test case for {@link Immutable}. * * @since 1.16 - * @checkstyle MagicNumber (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") diff --git a/src/test/java/org/cactoos/collection/NoNullsTest.java b/src/test/java/org/cactoos/collection/NoNullsTest.java index 30ea796f1..79f9ec9df 100644 --- a/src/test/java/org/cactoos/collection/NoNullsTest.java +++ b/src/test/java/org/cactoos/collection/NoNullsTest.java @@ -46,7 +46,6 @@ * * @since 0.35 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") diff --git a/src/test/java/org/cactoos/experimental/ThreadsTest.java b/src/test/java/org/cactoos/experimental/ThreadsTest.java index 2702bef6a..bbfcbc803 100644 --- a/src/test/java/org/cactoos/experimental/ThreadsTest.java +++ b/src/test/java/org/cactoos/experimental/ThreadsTest.java @@ -42,7 +42,6 @@ * * @since 1.0.0 * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") final class ThreadsTest { diff --git a/src/test/java/org/cactoos/func/ChainedTest.java b/src/test/java/org/cactoos/func/ChainedTest.java index ba1a40b1f..eac1e05f9 100644 --- a/src/test/java/org/cactoos/func/ChainedTest.java +++ b/src/test/java/org/cactoos/func/ChainedTest.java @@ -37,7 +37,6 @@ * * @since 0.7 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 line) */ final class ChainedTest { diff --git a/src/test/java/org/cactoos/func/FallbackFromTest.java b/src/test/java/org/cactoos/func/FallbackFromTest.java index 8653e03eb..60f367c22 100644 --- a/src/test/java/org/cactoos/func/FallbackFromTest.java +++ b/src/test/java/org/cactoos/func/FallbackFromTest.java @@ -35,7 +35,6 @@ * * @since 0.31 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("unchecked") final class FallbackFromTest { diff --git a/src/test/java/org/cactoos/func/RepeatedTest.java b/src/test/java/org/cactoos/func/RepeatedTest.java index e20780671..e8cc8a5b0 100644 --- a/src/test/java/org/cactoos/func/RepeatedTest.java +++ b/src/test/java/org/cactoos/func/RepeatedTest.java @@ -38,7 +38,6 @@ * * @since 0.13.1 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 line) */ final class RepeatedTest { diff --git a/src/test/java/org/cactoos/func/RetryTest.java b/src/test/java/org/cactoos/func/RetryTest.java index 250c6b52d..f33750108 100644 --- a/src/test/java/org/cactoos/func/RetryTest.java +++ b/src/test/java/org/cactoos/func/RetryTest.java @@ -35,7 +35,6 @@ * * @since 0.8 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 line) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") final class RetryTest { diff --git a/src/test/java/org/cactoos/io/DirectoryTest.java b/src/test/java/org/cactoos/io/DirectoryTest.java index cb3322c14..fafe21ccc 100644 --- a/src/test/java/org/cactoos/io/DirectoryTest.java +++ b/src/test/java/org/cactoos/io/DirectoryTest.java @@ -55,7 +55,6 @@ public void listsFilesAndFoldersInDirectory() throws IOException { new Assertion<>( "must list files in a directory represented by a path", new Directory(dir), - // @checkstyle MagicNumber (1 line) new HasSize(4) ).affirm(); } @@ -69,7 +68,6 @@ public void listsFilesInDirectoryByFile() throws Exception { new Assertion<>( "must list files in a directory represented by a file", new Directory(file), - // @checkstyle MagicNumber (1 line) new HasSize(4) ).affirm(); } diff --git a/src/test/java/org/cactoos/io/HeadInputStreamTest.java b/src/test/java/org/cactoos/io/HeadInputStreamTest.java index 816c2f3fe..ca4bd9ed9 100644 --- a/src/test/java/org/cactoos/io/HeadInputStreamTest.java +++ b/src/test/java/org/cactoos/io/HeadInputStreamTest.java @@ -35,7 +35,6 @@ * * @since 0.31 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") diff --git a/src/test/java/org/cactoos/io/HeadOfTest.java b/src/test/java/org/cactoos/io/HeadOfTest.java index 7b3f28a37..2f1caf53b 100644 --- a/src/test/java/org/cactoos/io/HeadOfTest.java +++ b/src/test/java/org/cactoos/io/HeadOfTest.java @@ -33,7 +33,6 @@ * * @since 0.31 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class HeadOfTest { diff --git a/src/test/java/org/cactoos/io/LoggingInputStreamTest.java b/src/test/java/org/cactoos/io/LoggingInputStreamTest.java index cb9baf75a..5dc1d2019 100644 --- a/src/test/java/org/cactoos/io/LoggingInputStreamTest.java +++ b/src/test/java/org/cactoos/io/LoggingInputStreamTest.java @@ -69,7 +69,6 @@ void readEmptyStream() throws IOException { new Assertion<>( "Empty stream did not return -1", stream.read(), - // @checkstyle MagicNumberCheck (1 line) new IsEqual<>(-1) ).affirm(); } @@ -79,7 +78,6 @@ void readByteByByte() throws IOException { final LoggingInputStream stream = new LoggingInputStream( new ByteArrayInputStream( new byte[] { - // @checkstyle MagicNumberCheck (2 lines) (byte) 20, (byte) 10, } @@ -89,19 +87,16 @@ void readByteByByte() throws IOException { new Assertion<>( "First byte was not 20", stream.read(), - // @checkstyle MagicNumberCheck (1 line) new IsEqual<>(20) ).affirm(); new Assertion<>( "Second byte was not 10", stream.read(), - // @checkstyle MagicNumberCheck (1 line) new IsEqual<>(10) ).affirm(); new Assertion<>( "When stream is exhausted it didn't return -1", stream.read(), - // @checkstyle MagicNumberCheck (1 line) new IsEqual<>(-1) ).affirm(); } diff --git a/src/test/java/org/cactoos/io/LoggingInputTest.java b/src/test/java/org/cactoos/io/LoggingInputTest.java index ae250fecc..92b84c676 100644 --- a/src/test/java/org/cactoos/io/LoggingInputTest.java +++ b/src/test/java/org/cactoos/io/LoggingInputTest.java @@ -156,7 +156,6 @@ void logSkipFromLargeTextFile() throws Exception { new ResourceOf("org/cactoos/large-text.txt"), "text file", logger - // @checkstyle MagicNumber (1 line) ).stream().skip(100); new Assertion<>( "Must log skip from text file", @@ -191,7 +190,6 @@ void logResetFromLargeTextFile() throws Exception { "text file", logger ).stream(); - // @checkstyle MagicNumber (1 line) input.mark(150); input.reset(); new Assertion<>( diff --git a/src/test/java/org/cactoos/io/ResourceOfTest.java b/src/test/java/org/cactoos/io/ResourceOfTest.java index 46b6fb698..232416138 100644 --- a/src/test/java/org/cactoos/io/ResourceOfTest.java +++ b/src/test/java/org/cactoos/io/ResourceOfTest.java @@ -54,13 +54,11 @@ public void readsBinaryResource() throws Exception { "org/cactoos/io/ResourceOfTest.class" ) ).asBytes(), - // @checkstyle MagicNumber (2 lines) 0, 4 ), new IsEqual<>( new byte[]{ - // @checkstyle MagicNumber (1 line) (byte) 0xCA, (byte) 0xFE, (byte) 0xBA, (byte) 0xBE, } ) diff --git a/src/test/java/org/cactoos/io/SlowInputStreamTest.java b/src/test/java/org/cactoos/io/SlowInputStreamTest.java index ee91f1462..dce2e4bd1 100644 --- a/src/test/java/org/cactoos/io/SlowInputStreamTest.java +++ b/src/test/java/org/cactoos/io/SlowInputStreamTest.java @@ -32,7 +32,6 @@ * Test for {@link SlowInputStream}. * * @since 0.47 - * @checkstyle MagicNumberCheck (40 lines) */ final class SlowInputStreamTest { diff --git a/src/test/java/org/cactoos/io/StickyTest.java b/src/test/java/org/cactoos/io/StickyTest.java index e1aa0d855..9dbd91e6c 100644 --- a/src/test/java/org/cactoos/io/StickyTest.java +++ b/src/test/java/org/cactoos/io/StickyTest.java @@ -55,7 +55,6 @@ void readsFileContent() { new Repeated<>( input -> new BytesOf( new TeeInput(input, new DeadOutput()) - // @checkstyle MagicNumber (2 lines) ).asBytes().length == 74_536, 10 ) diff --git a/src/test/java/org/cactoos/io/WriterAsOutputStreamTest.java b/src/test/java/org/cactoos/io/WriterAsOutputStreamTest.java index 26d1abf01..f338af711 100644 --- a/src/test/java/org/cactoos/io/WriterAsOutputStreamTest.java +++ b/src/test/java/org/cactoos/io/WriterAsOutputStreamTest.java @@ -68,7 +68,6 @@ public void writesToByteArray() { baos, StandardCharsets.UTF_8 ), StandardCharsets.UTF_8, - // @checkstyle MagicNumber (1 line) 13 ) ) @@ -95,7 +94,6 @@ public void writesLargeContentToFile() throws IOException { new WriterAsOutputStream( writer, StandardCharsets.UTF_8, - // @checkstyle MagicNumber (1 line) 345 ) ) @@ -122,7 +120,6 @@ public void writesToFileAndRemovesIt() throws Exception { new WriterAsOutputStream( writer, StandardCharsets.UTF_8, - // @checkstyle MagicNumber (1 line) 345 ) ) diff --git a/src/test/java/org/cactoos/io/ZipTest.java b/src/test/java/org/cactoos/io/ZipTest.java index 7fb035033..8fa6405b5 100644 --- a/src/test/java/org/cactoos/io/ZipTest.java +++ b/src/test/java/org/cactoos/io/ZipTest.java @@ -66,7 +66,6 @@ public void zip() throws Exception { new Assertion<>( "Can't list files in a directory represented by a path", cnt, - // @checkstyle MagicNumber (1 line) new IsEqual<>(4) ).affirm(); } diff --git a/src/test/java/org/cactoos/iterable/CycledTest.java b/src/test/java/org/cactoos/iterable/CycledTest.java index 337968e9a..836db212b 100644 --- a/src/test/java/org/cactoos/iterable/CycledTest.java +++ b/src/test/java/org/cactoos/iterable/CycledTest.java @@ -43,7 +43,6 @@ void repeatIterableTest() { new Assertion<>( "Must repeat iterable", new ItemAt<>( - // @checkstyle MagicNumberCheck (1 line)< 7, new Cycled<>( new IterableOf<>( "one", expected, "three" diff --git a/src/test/java/org/cactoos/iterable/FilteredTest.java b/src/test/java/org/cactoos/iterable/FilteredTest.java index 7eb6346ab..e7b9272a0 100644 --- a/src/test/java/org/cactoos/iterable/FilteredTest.java +++ b/src/test/java/org/cactoos/iterable/FilteredTest.java @@ -38,7 +38,6 @@ * Test case for {@link Filtered}. * @since 0.1 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ final class FilteredTest { @@ -49,7 +48,6 @@ void filtersList() throws Exception { "Must calculate the length of an iterable", new LengthOf( new Filtered<>( - // @checkstyle MagicNumber (1 line) input -> input.length() > 4, new IterableOf<>( "hello", "world", "друг" diff --git a/src/test/java/org/cactoos/iterable/IterableOfTest.java b/src/test/java/org/cactoos/iterable/IterableOfTest.java index 3d408798a..4adf8e81c 100644 --- a/src/test/java/org/cactoos/iterable/IterableOfTest.java +++ b/src/test/java/org/cactoos/iterable/IterableOfTest.java @@ -50,7 +50,6 @@ void convertsScalarsToIterable() throws Exception { "a", "b", "c" ) ), - // @checkstyle MagicNumber (1 line) new HasValue<>(3L) ).affirm(); } @@ -73,7 +72,6 @@ void convertsObjectsToIterable() throws Exception { new TextOf("a"), new TextOf("b"), new TextOf("c") ) ), - // @checkstyle MagicNumber (1 line) new HasValue<>(3L) ).affirm(); } diff --git a/src/test/java/org/cactoos/iterable/JoinedTest.java b/src/test/java/org/cactoos/iterable/JoinedTest.java index 2e5c51971..c5e8693cb 100644 --- a/src/test/java/org/cactoos/iterable/JoinedTest.java +++ b/src/test/java/org/cactoos/iterable/JoinedTest.java @@ -31,7 +31,6 @@ * Test case for {@link Joined}. * @since 0.1 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class JoinedTest { diff --git a/src/test/java/org/cactoos/iterable/MappedTest.java b/src/test/java/org/cactoos/iterable/MappedTest.java index 9bff1a18a..e42ef4b64 100644 --- a/src/test/java/org/cactoos/iterable/MappedTest.java +++ b/src/test/java/org/cactoos/iterable/MappedTest.java @@ -37,7 +37,6 @@ * Test case for {@link Mapped}. * @since 0.1 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ final class MappedTest { diff --git a/src/test/java/org/cactoos/iterable/MappedWithIndexTest.java b/src/test/java/org/cactoos/iterable/MappedWithIndexTest.java index 102289f59..9bcb6d568 100644 --- a/src/test/java/org/cactoos/iterable/MappedWithIndexTest.java +++ b/src/test/java/org/cactoos/iterable/MappedWithIndexTest.java @@ -33,7 +33,6 @@ /** * Tests for {@link MappedWithIndex}. * @since 1.0.0 - * @checkstyle MagicNumberCheck (500 lines) */ final class MappedWithIndexTest { @Test diff --git a/src/test/java/org/cactoos/iterable/MatchedTest.java b/src/test/java/org/cactoos/iterable/MatchedTest.java index 1e948d9fe..4aa367fb5 100644 --- a/src/test/java/org/cactoos/iterable/MatchedTest.java +++ b/src/test/java/org/cactoos/iterable/MatchedTest.java @@ -39,7 +39,6 @@ * Test case for {@link Matched}. * * @since 0.39 - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ diff --git a/src/test/java/org/cactoos/iterable/PartitionedTest.java b/src/test/java/org/cactoos/iterable/PartitionedTest.java index 0e1917543..0ab39fd82 100644 --- a/src/test/java/org/cactoos/iterable/PartitionedTest.java +++ b/src/test/java/org/cactoos/iterable/PartitionedTest.java @@ -33,7 +33,6 @@ * * @since 0.29 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class PartitionedTest { diff --git a/src/test/java/org/cactoos/iterable/RangeOfTest.java b/src/test/java/org/cactoos/iterable/RangeOfTest.java index 33bd637ed..c38d7ee1b 100644 --- a/src/test/java/org/cactoos/iterable/RangeOfTest.java +++ b/src/test/java/org/cactoos/iterable/RangeOfTest.java @@ -42,7 +42,6 @@ * * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ final class RangeOfTest { diff --git a/src/test/java/org/cactoos/iterable/RepeatedTest.java b/src/test/java/org/cactoos/iterable/RepeatedTest.java index 7003913a7..f7de52161 100644 --- a/src/test/java/org/cactoos/iterable/RepeatedTest.java +++ b/src/test/java/org/cactoos/iterable/RepeatedTest.java @@ -34,7 +34,6 @@ * * @since 0.1 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class RepeatedTest { diff --git a/src/test/java/org/cactoos/iterable/ReversedTest.java b/src/test/java/org/cactoos/iterable/ReversedTest.java index ba1e421c6..bd03f2784 100644 --- a/src/test/java/org/cactoos/iterable/ReversedTest.java +++ b/src/test/java/org/cactoos/iterable/ReversedTest.java @@ -35,7 +35,6 @@ * Test case for {@link Reversed}. * @since 0.9 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ public final class ReversedTest { diff --git a/src/test/java/org/cactoos/iterable/ShuffledTest.java b/src/test/java/org/cactoos/iterable/ShuffledTest.java index b837df8b9..86f4d2ce6 100644 --- a/src/test/java/org/cactoos/iterable/ShuffledTest.java +++ b/src/test/java/org/cactoos/iterable/ShuffledTest.java @@ -35,7 +35,6 @@ * * @since 0.20 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class ShuffledTest { diff --git a/src/test/java/org/cactoos/iterable/SlicedTest.java b/src/test/java/org/cactoos/iterable/SlicedTest.java index 4eb93aa5d..5f54aa628 100644 --- a/src/test/java/org/cactoos/iterable/SlicedTest.java +++ b/src/test/java/org/cactoos/iterable/SlicedTest.java @@ -31,7 +31,6 @@ * Test case for {@link Sliced}. * @since 1.0.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class SlicedTest { diff --git a/src/test/java/org/cactoos/iterable/SolidTest.java b/src/test/java/org/cactoos/iterable/SolidTest.java index 2f73f4707..5a7ce7cca 100644 --- a/src/test/java/org/cactoos/iterable/SolidTest.java +++ b/src/test/java/org/cactoos/iterable/SolidTest.java @@ -33,7 +33,6 @@ * Test Case for {@link Solid}. * @since 0.24 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class SolidTest { diff --git a/src/test/java/org/cactoos/iterable/SortedTest.java b/src/test/java/org/cactoos/iterable/SortedTest.java index 3fd342d63..ca9485022 100644 --- a/src/test/java/org/cactoos/iterable/SortedTest.java +++ b/src/test/java/org/cactoos/iterable/SortedTest.java @@ -36,7 +36,6 @@ * * @since 0.7 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class SortedTest { diff --git a/src/test/java/org/cactoos/iterable/SyncedTest.java b/src/test/java/org/cactoos/iterable/SyncedTest.java index fa70f5fd1..6bede9c1a 100644 --- a/src/test/java/org/cactoos/iterable/SyncedTest.java +++ b/src/test/java/org/cactoos/iterable/SyncedTest.java @@ -32,7 +32,6 @@ * Test Case for {@link Synced}. * @since 0.24 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class SyncedTest { diff --git a/src/test/java/org/cactoos/iterable/TailOfTest.java b/src/test/java/org/cactoos/iterable/TailOfTest.java index 5e173a8f4..d952899df 100644 --- a/src/test/java/org/cactoos/iterable/TailOfTest.java +++ b/src/test/java/org/cactoos/iterable/TailOfTest.java @@ -31,7 +31,6 @@ * Test case for {@link TailOf}. * @since 0.31 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class TailOfTest { diff --git a/src/test/java/org/cactoos/iterator/CycledTest.java b/src/test/java/org/cactoos/iterator/CycledTest.java index af1dede4f..272ac8ca8 100644 --- a/src/test/java/org/cactoos/iterator/CycledTest.java +++ b/src/test/java/org/cactoos/iterator/CycledTest.java @@ -45,7 +45,6 @@ public void repeatIteratorTest() { new Assertion<>( "must repeat iterator", new ItemAt<>( - // @checkstyle MagicNumberCheck (1 line) 7, new IterableOf<>( new Cycled<>( diff --git a/src/test/java/org/cactoos/iterator/HeadOfTest.java b/src/test/java/org/cactoos/iterator/HeadOfTest.java index ff528a112..b75549d41 100644 --- a/src/test/java/org/cactoos/iterator/HeadOfTest.java +++ b/src/test/java/org/cactoos/iterator/HeadOfTest.java @@ -37,7 +37,6 @@ * Test Case for {@link HeadOf}. * @since 0.8 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class HeadOfTest { diff --git a/src/test/java/org/cactoos/iterator/JoinedTest.java b/src/test/java/org/cactoos/iterator/JoinedTest.java index b9f301603..19e54266f 100644 --- a/src/test/java/org/cactoos/iterator/JoinedTest.java +++ b/src/test/java/org/cactoos/iterator/JoinedTest.java @@ -35,7 +35,6 @@ * @since 0.14 * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class JoinedTest { diff --git a/src/test/java/org/cactoos/iterator/MatchedTest.java b/src/test/java/org/cactoos/iterator/MatchedTest.java index e92620b5a..3d18ff535 100644 --- a/src/test/java/org/cactoos/iterator/MatchedTest.java +++ b/src/test/java/org/cactoos/iterator/MatchedTest.java @@ -34,7 +34,6 @@ /** * Test case for {@link Mapped}. * @since 0.47 - * @checkstyle MagicNumberCheck (500 lines) */ final class MatchedTest { @Test diff --git a/src/test/java/org/cactoos/iterator/PagedTest.java b/src/test/java/org/cactoos/iterator/PagedTest.java index 08bb5ae0d..8985bd49b 100644 --- a/src/test/java/org/cactoos/iterator/PagedTest.java +++ b/src/test/java/org/cactoos/iterator/PagedTest.java @@ -42,7 +42,6 @@ * Test case for {@link Paged}. * @since 0.47 * @checkstyle ClassDataAbstractionCoupling (2 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") diff --git a/src/test/java/org/cactoos/iterator/PartitionedTest.java b/src/test/java/org/cactoos/iterator/PartitionedTest.java index 4ddb0628f..efb62dbd9 100644 --- a/src/test/java/org/cactoos/iterator/PartitionedTest.java +++ b/src/test/java/org/cactoos/iterator/PartitionedTest.java @@ -40,7 +40,6 @@ * * @since 0.29 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ public final class PartitionedTest { diff --git a/src/test/java/org/cactoos/iterator/RangeOfTest.java b/src/test/java/org/cactoos/iterator/RangeOfTest.java index e00c3e264..19bc4edb9 100644 --- a/src/test/java/org/cactoos/iterator/RangeOfTest.java +++ b/src/test/java/org/cactoos/iterator/RangeOfTest.java @@ -35,7 +35,6 @@ * Test of range implementation. * * @since 1.0 - * @checkstyle MagicNumber (500 lines) */ final class RangeOfTest { diff --git a/src/test/java/org/cactoos/iterator/ReversedTest.java b/src/test/java/org/cactoos/iterator/ReversedTest.java index 4db8fb5ac..51a6f5317 100644 --- a/src/test/java/org/cactoos/iterator/ReversedTest.java +++ b/src/test/java/org/cactoos/iterator/ReversedTest.java @@ -34,7 +34,6 @@ * Test case for {@link Reversed}. * * @since 0.45 - * @checkstyle MagicNumberCheck (500 lines) */ final class ReversedTest { diff --git a/src/test/java/org/cactoos/iterator/SlicedTest.java b/src/test/java/org/cactoos/iterator/SlicedTest.java index 93191e90b..f80b2aef5 100644 --- a/src/test/java/org/cactoos/iterator/SlicedTest.java +++ b/src/test/java/org/cactoos/iterator/SlicedTest.java @@ -35,7 +35,6 @@ * Test for {@link Sliced}. * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class SlicedTest { diff --git a/src/test/java/org/cactoos/iterator/SyncedTest.java b/src/test/java/org/cactoos/iterator/SyncedTest.java index eee3cc874..43a230700 100644 --- a/src/test/java/org/cactoos/iterator/SyncedTest.java +++ b/src/test/java/org/cactoos/iterator/SyncedTest.java @@ -36,7 +36,6 @@ * * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle TodoCommentCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") diff --git a/src/test/java/org/cactoos/iterator/TailOfTest.java b/src/test/java/org/cactoos/iterator/TailOfTest.java index 47bd72f82..896cf780d 100644 --- a/src/test/java/org/cactoos/iterator/TailOfTest.java +++ b/src/test/java/org/cactoos/iterator/TailOfTest.java @@ -35,7 +35,6 @@ * Test case for {@link TailOf}. * @since 0.31 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class TailOfTest { diff --git a/src/test/java/org/cactoos/list/ImmutableListIteratorTest.java b/src/test/java/org/cactoos/list/ImmutableListIteratorTest.java index e74d3bb94..d86a534b6 100644 --- a/src/test/java/org/cactoos/list/ImmutableListIteratorTest.java +++ b/src/test/java/org/cactoos/list/ImmutableListIteratorTest.java @@ -33,7 +33,6 @@ * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle JavadocTypeCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings({"PMD.TooManyMethods", "PMD.AvoidDuplicateLiterals"}) final class ImmutableListIteratorTest { diff --git a/src/test/java/org/cactoos/list/ImmutableTest.java b/src/test/java/org/cactoos/list/ImmutableTest.java index f1150c8a5..ce88055f3 100644 --- a/src/test/java/org/cactoos/list/ImmutableTest.java +++ b/src/test/java/org/cactoos/list/ImmutableTest.java @@ -38,7 +38,6 @@ * Test case for {@link Immutable}. * * @since 1.16 - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings({"PMD.TooManyMethods", "PMD.AvoidDuplicateLiterals"}) diff --git a/src/test/java/org/cactoos/list/JoinedListIteratorTest.java b/src/test/java/org/cactoos/list/JoinedListIteratorTest.java index 770c079df..cf914d056 100644 --- a/src/test/java/org/cactoos/list/JoinedListIteratorTest.java +++ b/src/test/java/org/cactoos/list/JoinedListIteratorTest.java @@ -36,7 +36,6 @@ * @since 1.0.0 * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) - * @checkstyle MagicNumber (500 lines) */ final class JoinedListIteratorTest { diff --git a/src/test/java/org/cactoos/list/JoinedTest.java b/src/test/java/org/cactoos/list/JoinedTest.java index dcb386dea..335b17d51 100644 --- a/src/test/java/org/cactoos/list/JoinedTest.java +++ b/src/test/java/org/cactoos/list/JoinedTest.java @@ -38,7 +38,6 @@ * * @since 0.20 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 line) * @checkstyle DiamondOperatorCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ diff --git a/src/test/java/org/cactoos/list/ListEnvelopeTest.java b/src/test/java/org/cactoos/list/ListEnvelopeTest.java index e80b5a372..ba0ffa6a8 100644 --- a/src/test/java/org/cactoos/list/ListEnvelopeTest.java +++ b/src/test/java/org/cactoos/list/ListEnvelopeTest.java @@ -39,7 +39,6 @@ * @since 0.32 * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle JavadocTypeCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings({"PMD.TooManyMethods", "PMD.AvoidDuplicateLiterals"}) diff --git a/src/test/java/org/cactoos/list/ListIteratorEnvelopeTest.java b/src/test/java/org/cactoos/list/ListIteratorEnvelopeTest.java index d62ee36ff..85ee4bec3 100644 --- a/src/test/java/org/cactoos/list/ListIteratorEnvelopeTest.java +++ b/src/test/java/org/cactoos/list/ListIteratorEnvelopeTest.java @@ -33,7 +33,6 @@ * @since 0.35 * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle JavadocTypeCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class ListIteratorEnvelopeTest { @Test diff --git a/src/test/java/org/cactoos/list/ListIteratorNoNullsTest.java b/src/test/java/org/cactoos/list/ListIteratorNoNullsTest.java index d14909cf9..f81baf87f 100644 --- a/src/test/java/org/cactoos/list/ListIteratorNoNullsTest.java +++ b/src/test/java/org/cactoos/list/ListIteratorNoNullsTest.java @@ -37,7 +37,6 @@ * * @since 0.35 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class ListIteratorNoNullsTest { diff --git a/src/test/java/org/cactoos/list/ListOfTest.java b/src/test/java/org/cactoos/list/ListOfTest.java index 11f9e1a84..91a212839 100644 --- a/src/test/java/org/cactoos/list/ListOfTest.java +++ b/src/test/java/org/cactoos/list/ListOfTest.java @@ -38,7 +38,6 @@ * @since 0.1 * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings( { @@ -91,13 +90,11 @@ public void emptyTest() throws Exception { @Test(expected = IndexOutOfBoundsException.class) public void lowBoundTest() throws Exception { - // @checkstyle MagicNumber (1 line) new ListOf<>(Collections.nCopies(10, 0)).get(-1); } @Test(expected = IndexOutOfBoundsException.class) public void highBoundTest() throws Exception { - // @checkstyle MagicNumber (1 line) new ListOf<>(Collections.nCopies(10, 0)).get(11); } diff --git a/src/test/java/org/cactoos/list/NoNullsTest.java b/src/test/java/org/cactoos/list/NoNullsTest.java index c6ce16269..b3b64097d 100644 --- a/src/test/java/org/cactoos/list/NoNullsTest.java +++ b/src/test/java/org/cactoos/list/NoNullsTest.java @@ -34,7 +34,6 @@ * Test cases for {@link NoNulls}. * @since 0.35 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class NoNullsTest { diff --git a/src/test/java/org/cactoos/map/GroupedTest.java b/src/test/java/org/cactoos/map/GroupedTest.java index 016d1b90d..cbffa9a95 100644 --- a/src/test/java/org/cactoos/map/GroupedTest.java +++ b/src/test/java/org/cactoos/map/GroupedTest.java @@ -45,7 +45,6 @@ void groupedByNumber() throws Exception { new Assertion<>( "Can't behave as a map", new Grouped<>( - // @checkstyle MagicNumberCheck (1 line) new IterableOf<>(1, 1, 1, 4, 5, 6, 7, 8, 9), number -> number, Object::toString @@ -72,7 +71,6 @@ void groupedByOneHasEntries() throws Exception { new Assertion<>( "Can't group int values", new Grouped<>( - // @checkstyle MagicNumberCheck (1 line) new IterableOf<>(1, 1, 1, 4, 5, 6, 7, 8, 9), number -> number, Object::toString @@ -89,7 +87,6 @@ void groupedBySuperType() throws Exception { new Assertion<>( "Must group Number values", new Grouped<>( - // @checkstyle MagicNumberCheck (1 line) new IterableOf(1, 1f, 1L, 4f, 5, 6f, 7, 8f, 9), Number::intValue, Object::toString diff --git a/src/test/java/org/cactoos/map/MapEntryTest.java b/src/test/java/org/cactoos/map/MapEntryTest.java index 7542910f4..04678a004 100644 --- a/src/test/java/org/cactoos/map/MapEntryTest.java +++ b/src/test/java/org/cactoos/map/MapEntryTest.java @@ -78,7 +78,6 @@ public void compareHash() { MatcherAssert.assertThat( "the hash code are not equals", new MapEntry<>("elegant", "objects").hashCode(), - // @checkstyle MagicNumber (1 line) new IsEqual<>(32_739_498) ); } diff --git a/src/test/java/org/cactoos/number/AvgOfTest.java b/src/test/java/org/cactoos/number/AvgOfTest.java index 593fcdbd7..4045fff64 100644 --- a/src/test/java/org/cactoos/number/AvgOfTest.java +++ b/src/test/java/org/cactoos/number/AvgOfTest.java @@ -35,7 +35,6 @@ * * @since 0.24 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") public final class AvgOfTest { diff --git a/src/test/java/org/cactoos/number/DivisionOfTest.java b/src/test/java/org/cactoos/number/DivisionOfTest.java index 6ebab305e..ab93683c3 100644 --- a/src/test/java/org/cactoos/number/DivisionOfTest.java +++ b/src/test/java/org/cactoos/number/DivisionOfTest.java @@ -33,7 +33,6 @@ * Test case for {@link DivisionOf}. * * @since 0.49.2 - * @checkstyle MagicNumberCheck (500 lines) */ final class DivisionOfTest { diff --git a/src/test/java/org/cactoos/number/MaxOfTest.java b/src/test/java/org/cactoos/number/MaxOfTest.java index 34bcd434f..8d1b9bf64 100644 --- a/src/test/java/org/cactoos/number/MaxOfTest.java +++ b/src/test/java/org/cactoos/number/MaxOfTest.java @@ -31,7 +31,6 @@ * Test case for {@link MaxOf}. * * @since 0.10 - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") final class MaxOfTest { diff --git a/src/test/java/org/cactoos/number/MinOfTest.java b/src/test/java/org/cactoos/number/MinOfTest.java index fe7c11788..7af1a141d 100644 --- a/src/test/java/org/cactoos/number/MinOfTest.java +++ b/src/test/java/org/cactoos/number/MinOfTest.java @@ -32,7 +32,6 @@ * Test case for {@link MinOf}. * * @since 0.10 - * @checkstyle MagicNumberCheck (500 lines) */ final class MinOfTest { diff --git a/src/test/java/org/cactoos/number/MultiplicationOfTest.java b/src/test/java/org/cactoos/number/MultiplicationOfTest.java index 45bf7644c..2eb1fab4c 100644 --- a/src/test/java/org/cactoos/number/MultiplicationOfTest.java +++ b/src/test/java/org/cactoos/number/MultiplicationOfTest.java @@ -34,7 +34,6 @@ * Test case for {@link MultiplicationOf}. * * @since 0.49.2 - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") public final class MultiplicationOfTest { diff --git a/src/test/java/org/cactoos/number/NumberEnvelopeTest.java b/src/test/java/org/cactoos/number/NumberEnvelopeTest.java index 8e1a2f0fa..de658cea9 100644 --- a/src/test/java/org/cactoos/number/NumberEnvelopeTest.java +++ b/src/test/java/org/cactoos/number/NumberEnvelopeTest.java @@ -39,7 +39,6 @@ * Test case for {@link NumberEnvelope}. * * @since 1.0.0 - * @checkstyle MagicNumber (500 lines) */ @SuppressWarnings({ "serial", "PMD.TooManyMethods" }) final class NumberEnvelopeTest implements ArgumentsProvider { diff --git a/src/test/java/org/cactoos/number/NumberOfScalarsTest.java b/src/test/java/org/cactoos/number/NumberOfScalarsTest.java index 9feb8bc5d..345d4b460 100644 --- a/src/test/java/org/cactoos/number/NumberOfScalarsTest.java +++ b/src/test/java/org/cactoos/number/NumberOfScalarsTest.java @@ -39,7 +39,6 @@ * Test case for {@link NumberOfScalars}. * * @since 1.0.0 - * @checkstyle MagicNumber (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") final class NumberOfScalarsTest implements ArgumentsProvider { diff --git a/src/test/java/org/cactoos/number/NumberOfTest.java b/src/test/java/org/cactoos/number/NumberOfTest.java index 353f72b15..a45adb075 100644 --- a/src/test/java/org/cactoos/number/NumberOfTest.java +++ b/src/test/java/org/cactoos/number/NumberOfTest.java @@ -34,7 +34,6 @@ * Test case for {@link NumberOf}. * * @since 1.0.0 - * @checkstyle MagicNumber (500 lines) */ final class NumberOfTest { diff --git a/src/test/java/org/cactoos/number/SumOfTest.java b/src/test/java/org/cactoos/number/SumOfTest.java index 5869748f4..1d49b8500 100644 --- a/src/test/java/org/cactoos/number/SumOfTest.java +++ b/src/test/java/org/cactoos/number/SumOfTest.java @@ -40,7 +40,6 @@ * thoroughly what is a "correct" behaviour concerning overflow in the case * of SumOf and adapt the tests and the code to make this obvious and clear. * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") final class SumOfTest { diff --git a/src/test/java/org/cactoos/proc/ForEachTest.java b/src/test/java/org/cactoos/proc/ForEachTest.java index dd52a9330..e02088ac8 100644 --- a/src/test/java/org/cactoos/proc/ForEachTest.java +++ b/src/test/java/org/cactoos/proc/ForEachTest.java @@ -34,7 +34,6 @@ * Test case for {@link ForEach}. * * @since 1.0 - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("unchecked") final class ForEachTest { diff --git a/src/test/java/org/cactoos/proc/RepeatedProcTest.java b/src/test/java/org/cactoos/proc/RepeatedProcTest.java index f6c09902e..a23cb4398 100644 --- a/src/test/java/org/cactoos/proc/RepeatedProcTest.java +++ b/src/test/java/org/cactoos/proc/RepeatedProcTest.java @@ -34,7 +34,6 @@ * Test case for {@link RepeatedProc}. * * @since 0.49.2 - * @checkstyle MagicNumberCheck (100 line) */ final class RepeatedProcTest { diff --git a/src/test/java/org/cactoos/scalar/AndTest.java b/src/test/java/org/cactoos/scalar/AndTest.java index 59205732d..8f771d1bd 100644 --- a/src/test/java/org/cactoos/scalar/AndTest.java +++ b/src/test/java/org/cactoos/scalar/AndTest.java @@ -34,7 +34,6 @@ * Test case for {@link And}. * @since 0.8 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 line) */ @SuppressWarnings("PMD.TooManyMethods") final class AndTest { diff --git a/src/test/java/org/cactoos/scalar/EqualityTest.java b/src/test/java/org/cactoos/scalar/EqualityTest.java index 248579c00..e880ab0ba 100644 --- a/src/test/java/org/cactoos/scalar/EqualityTest.java +++ b/src/test/java/org/cactoos/scalar/EqualityTest.java @@ -32,7 +32,6 @@ * Test case for {@link Equality}. * @since 0.31 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class EqualityTest { diff --git a/src/test/java/org/cactoos/scalar/FirstOfTest.java b/src/test/java/org/cactoos/scalar/FirstOfTest.java index 8de081b62..7843baa6e 100644 --- a/src/test/java/org/cactoos/scalar/FirstOfTest.java +++ b/src/test/java/org/cactoos/scalar/FirstOfTest.java @@ -104,7 +104,6 @@ void throwsFallbackIfNothingMatches() { "Fallback was not thrown", new FirstOf<>( num -> num.equals(0), - // @checkstyle MagicNumber (10 lines) new IterableOf<>( 1, 2, 3, 4, 5 ), diff --git a/src/test/java/org/cactoos/scalar/FoldedTest.java b/src/test/java/org/cactoos/scalar/FoldedTest.java index 0733d0feb..89b85f8ee 100644 --- a/src/test/java/org/cactoos/scalar/FoldedTest.java +++ b/src/test/java/org/cactoos/scalar/FoldedTest.java @@ -34,7 +34,6 @@ * Test case for {@link Folded}. * @since 0.30 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class FoldedTest { diff --git a/src/test/java/org/cactoos/scalar/HighestOfTest.java b/src/test/java/org/cactoos/scalar/HighestOfTest.java index 4e824d341..c75daab0f 100644 --- a/src/test/java/org/cactoos/scalar/HighestOfTest.java +++ b/src/test/java/org/cactoos/scalar/HighestOfTest.java @@ -40,7 +40,6 @@ * * @since 0.29 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") public final class HighestOfTest { diff --git a/src/test/java/org/cactoos/scalar/ItemAtTest.java b/src/test/java/org/cactoos/scalar/ItemAtTest.java index 3abd2ac81..5cf33e659 100644 --- a/src/test/java/org/cactoos/scalar/ItemAtTest.java +++ b/src/test/java/org/cactoos/scalar/ItemAtTest.java @@ -44,7 +44,6 @@ void elementByPosIterableTest() { new Assertion<>( "must take the item by position from the iterable", new ItemAt<>( - // @checkstyle MagicNumber (1 line) 1, new IterableOf<>(1, 2, 3) ), new HasValue<>(2) @@ -70,7 +69,6 @@ void elementByPosNoFallbackIterableTest() { new Assertion<>( "must take the item by position from the iterable", new ItemAt<>( - // @checkstyle MagicNumber (1 line) 1, 5, new IterableOf<>(0, 1) ), new HasValue<>(1) @@ -83,7 +81,6 @@ void elementByPosTest() { "must take the item by position from the iterator", new ItemAt<>( 1, - // @checkstyle MagicNumber (1 line) new IterableOf<>(1, 2, 3) ), new HasValue<>(2) @@ -96,7 +93,6 @@ void failForNegativePositionTest() { "Must fail for negative position", () -> new ItemAt<>( -1, - // @checkstyle MagicNumber (1 line) new IterableOf<>(1, 2, 3) ).value(), new Throws<>( @@ -111,7 +107,6 @@ void failForPosMoreLengthTest() { new Assertion<>( "Must fail for greater than length position", () -> new ItemAt<>( - // @checkstyle MagicNumberCheck (2 lines) 3, new IterableOf<>(1, 2, 3) ).value(), @@ -126,7 +121,6 @@ void failForPosMoreLengthTest() { void sameValueTest() throws Exception { final ItemAt item = new ItemAt<>( 1, - // @checkstyle MagicNumberCheck (1 lines) new IterableOf<>(1, 2, 3) ); new Assertion<>( diff --git a/src/test/java/org/cactoos/scalar/LengthOfTest.java b/src/test/java/org/cactoos/scalar/LengthOfTest.java index b4fe54712..df703fd36 100644 --- a/src/test/java/org/cactoos/scalar/LengthOfTest.java +++ b/src/test/java/org/cactoos/scalar/LengthOfTest.java @@ -36,7 +36,6 @@ * Test case for {@link LengthOf}. * * @since 0.1.0 - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ final class LengthOfTest { diff --git a/src/test/java/org/cactoos/scalar/LowestOfTest.java b/src/test/java/org/cactoos/scalar/LowestOfTest.java index 69ecc3cdd..361ff9452 100644 --- a/src/test/java/org/cactoos/scalar/LowestOfTest.java +++ b/src/test/java/org/cactoos/scalar/LowestOfTest.java @@ -40,7 +40,6 @@ * * @since 0.29 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") public final class LowestOfTest { diff --git a/src/test/java/org/cactoos/scalar/OrTest.java b/src/test/java/org/cactoos/scalar/OrTest.java index e980dd696..73f49d310 100644 --- a/src/test/java/org/cactoos/scalar/OrTest.java +++ b/src/test/java/org/cactoos/scalar/OrTest.java @@ -38,7 +38,6 @@ * * @since 0.8 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumber (500 line) */ @SuppressWarnings("PMD.TooManyMethods") final class OrTest { diff --git a/src/test/java/org/cactoos/scalar/RepeatedTest.java b/src/test/java/org/cactoos/scalar/RepeatedTest.java index 7f7daf357..fa2f97ff5 100644 --- a/src/test/java/org/cactoos/scalar/RepeatedTest.java +++ b/src/test/java/org/cactoos/scalar/RepeatedTest.java @@ -33,7 +33,6 @@ * Test case for {@link Repeated}. * * @since 0.49.2 - * @checkstyle MagicNumberCheck (100 line) * @checkstyle JavadocMethodCheck (100 lines) */ final class RepeatedTest { diff --git a/src/test/java/org/cactoos/scalar/RetryTest.java b/src/test/java/org/cactoos/scalar/RetryTest.java index 58a08e9d4..320df82b0 100644 --- a/src/test/java/org/cactoos/scalar/RetryTest.java +++ b/src/test/java/org/cactoos/scalar/RetryTest.java @@ -49,7 +49,6 @@ void runsScalarMultipleTimes() throws Exception { "must retry in case of failure", new Retry<>( () -> { - // @checkstyle MagicNumberCheck (1 line) if (new SecureRandom().nextDouble() > 0.3d) { throw new IllegalArgumentException("May happen"); } @@ -63,13 +62,11 @@ void runsScalarMultipleTimes() throws Exception { @Test void runsScalarTwiceWithDefaults() throws Exception { - // @checkstyle MagicNumberCheck (1 line) final AtomicInteger tries = new AtomicInteger(0); new Assertion<>( "Should run twice with defaults", new Retry<>( () -> { - // @checkstyle MagicNumberCheck (1 line) if (tries.getAndIncrement() <= 1) { throw new IllegalArgumentException("Not enough tries"); } @@ -83,7 +80,6 @@ void runsScalarTwiceWithDefaults() throws Exception { @Test void runsScalarMultipleTimesIgnoringNegativeDuration() throws Exception { - // @checkstyle MagicNumberCheck (2 line) final int times = 2; final AtomicInteger tries = new AtomicInteger(0); new Assertion<>( @@ -96,7 +92,6 @@ void runsScalarMultipleTimesIgnoringNegativeDuration() return 0; }, Integer.MAX_VALUE, - // @checkstyle MagicNumberCheck (1 line) Duration.of(-5, ChronoUnit.DAYS) ), new HasValue<>(0) @@ -106,7 +101,6 @@ void runsScalarMultipleTimesIgnoringNegativeDuration() @Test @SuppressWarnings("PMD.AvoidInstantiatingObjectsInLoops") void runsScalarMultipleTimesWithWait() throws Exception { - // @checkstyle MagicNumberCheck (3 line) final int times = 3; final long wait = 500; final AtomicInteger tries = new AtomicInteger(0); diff --git a/src/test/java/org/cactoos/scalar/TernaryTest.java b/src/test/java/org/cactoos/scalar/TernaryTest.java index a03c58485..f92569232 100644 --- a/src/test/java/org/cactoos/scalar/TernaryTest.java +++ b/src/test/java/org/cactoos/scalar/TernaryTest.java @@ -37,7 +37,6 @@ * Test case for {@link Ternary}. * @since 0.8 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ final class TernaryTest { diff --git a/src/test/java/org/cactoos/set/SetOfTest.java b/src/test/java/org/cactoos/set/SetOfTest.java index 937eb6f41..871a62b16 100644 --- a/src/test/java/org/cactoos/set/SetOfTest.java +++ b/src/test/java/org/cactoos/set/SetOfTest.java @@ -36,7 +36,6 @@ /** * Test case for {@link SetOf}. * @since 0.49.2 - * @checkstyle MagicNumber (500 line) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") diff --git a/src/test/java/org/cactoos/set/SortedTest.java b/src/test/java/org/cactoos/set/SortedTest.java index 5e8a71e3e..42d47119a 100644 --- a/src/test/java/org/cactoos/set/SortedTest.java +++ b/src/test/java/org/cactoos/set/SortedTest.java @@ -39,7 +39,6 @@ /** * Test case for {@link Sorted}. * @since 1.0.0 - * @checkstyle MagicNumber (500 line) * @checkstyle JavadocMethodCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ diff --git a/src/test/java/org/cactoos/text/AbbreviatedTest.java b/src/test/java/org/cactoos/text/AbbreviatedTest.java index 82d82fead..92c90c900 100644 --- a/src/test/java/org/cactoos/text/AbbreviatedTest.java +++ b/src/test/java/org/cactoos/text/AbbreviatedTest.java @@ -34,7 +34,6 @@ * Test case for {@link Abbreviated}. * @since 0.29 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) * @checkstyle ClassDataAbstractionCouplingCheck (500 lines) */ @SuppressWarnings("PMD.TooManyMethods") diff --git a/src/test/java/org/cactoos/text/ComparableTextTest.java b/src/test/java/org/cactoos/text/ComparableTextTest.java index fb9397b3d..2d5767ad5 100644 --- a/src/test/java/org/cactoos/text/ComparableTextTest.java +++ b/src/test/java/org/cactoos/text/ComparableTextTest.java @@ -48,7 +48,6 @@ public void comparesWithASubtext() { "here to there" ) ).compareTo( - // @checkstyle MagicNumberCheck (2 lines) new ComparableText( new Sub("from here to there", 5) ) diff --git a/src/test/java/org/cactoos/text/FormattedTextTest.java b/src/test/java/org/cactoos/text/FormattedTextTest.java index f2e712a2d..519ea1851 100644 --- a/src/test/java/org/cactoos/text/FormattedTextTest.java +++ b/src/test/java/org/cactoos/text/FormattedTextTest.java @@ -98,7 +98,6 @@ public void formatsWithLocale() { new Assertion<>( "Can't format a text with Locale", new FormattedText( - // @checkstyle MagicNumber (1 line) "%,d", Locale.GERMAN, 1_234_567_890 ), new HasString("1.234.567.890") diff --git a/src/test/java/org/cactoos/text/RandomizedTest.java b/src/test/java/org/cactoos/text/RandomizedTest.java index 1bff1f292..1eb5b7f25 100644 --- a/src/test/java/org/cactoos/text/RandomizedTest.java +++ b/src/test/java/org/cactoos/text/RandomizedTest.java @@ -36,7 +36,6 @@ * * @since 0.32 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ final class RandomizedTest { diff --git a/src/test/java/org/cactoos/text/RepeatedTest.java b/src/test/java/org/cactoos/text/RepeatedTest.java index 4dd889976..94e79030b 100644 --- a/src/test/java/org/cactoos/text/RepeatedTest.java +++ b/src/test/java/org/cactoos/text/RepeatedTest.java @@ -38,7 +38,6 @@ final class RepeatedTest { void repeatsWordsText() { new Assertion<>( "Can't repeats a text", - // @checkstyle MagicNumber (1 line) new Repeated("hello", 2), new HasString("hellohello") ).affirm(); @@ -48,7 +47,6 @@ void repeatsWordsText() { void repeatsCharText() { new Assertion<>( "Can't repeats a char", - // @checkstyle MagicNumber (1 line) new Repeated("A", 5), new HasString("AAAAA") ).affirm(); diff --git a/src/test/java/org/cactoos/text/ReplacedTest.java b/src/test/java/org/cactoos/text/ReplacedTest.java index 6d4a83c93..68c251a94 100644 --- a/src/test/java/org/cactoos/text/ReplacedTest.java +++ b/src/test/java/org/cactoos/text/ReplacedTest.java @@ -157,7 +157,6 @@ void invalidRegex() { new PatternSyntaxException( "Unclosed counted closure", regex, - // @checkstyle MagicNumberCheck (1 line) 16 ).getMessage(), PatternSyntaxException.class diff --git a/src/test/java/org/cactoos/text/StrictTest.java b/src/test/java/org/cactoos/text/StrictTest.java index fb6b2bd01..fc4c011ff 100644 --- a/src/test/java/org/cactoos/text/StrictTest.java +++ b/src/test/java/org/cactoos/text/StrictTest.java @@ -35,7 +35,6 @@ * Test case for {@link Strict}. * * @since 1.0 - * @checkstyle MagicNumber (500 line) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") final class StrictTest { diff --git a/src/test/java/org/cactoos/text/SubTest.java b/src/test/java/org/cactoos/text/SubTest.java index c00b7aaf2..2bf53bc94 100644 --- a/src/test/java/org/cactoos/text/SubTest.java +++ b/src/test/java/org/cactoos/text/SubTest.java @@ -53,7 +53,6 @@ void acceptsCharSequence() { void cutTextWithStartAndEnd() { new Assertion<>( "Can't cut a text with start and end", - // @checkstyle MagicNumber (1 line) new Sub("hello world", 2, 50), new HasString("llo world") ).affirm(); diff --git a/src/test/java/org/cactoos/text/TextOfDateTimeTest.java b/src/test/java/org/cactoos/text/TextOfDateTimeTest.java index e93294cc4..827da52c8 100644 --- a/src/test/java/org/cactoos/text/TextOfDateTimeTest.java +++ b/src/test/java/org/cactoos/text/TextOfDateTimeTest.java @@ -47,7 +47,6 @@ * * @since 1.0.0 * @checkstyle ClassDataAbstractionCouplingCheck (1000 lines) - * @checkstyle MagicNumberCheck (1000 lines) * @checkstyle StringLiteralsConcatenationCheck (1000 lines) */ @SuppressWarnings({"PMD.TooManyMethods", "PMD.AvoidDuplicateLiterals"}) diff --git a/src/test/java/org/cactoos/text/TextOfTest.java b/src/test/java/org/cactoos/text/TextOfTest.java index f24131db1..a42d97bb6 100644 --- a/src/test/java/org/cactoos/text/TextOfTest.java +++ b/src/test/java/org/cactoos/text/TextOfTest.java @@ -48,7 +48,6 @@ * @since 0.12 * @checkstyle JavadocMethodCheck (1000 lines) * @checkstyle ClassDataAbstractionCouplingCheck (1000 lines) - * @checkstyle MagicNumberCheck (1000 lines) * @checkstyle StringLiteralsConcatenationCheck (1000 lines) */ @SuppressWarnings({"PMD.TooManyMethods", "PMD.AvoidDuplicateLiterals", "unchecked"}) diff --git a/src/test/java/org/cactoos/time/DateOfTest.java b/src/test/java/org/cactoos/time/DateOfTest.java index 5f5f3f43d..46e838f40 100644 --- a/src/test/java/org/cactoos/time/DateOfTest.java +++ b/src/test/java/org/cactoos/time/DateOfTest.java @@ -35,7 +35,6 @@ * Tests for DateOf. * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") public class DateOfTest { diff --git a/src/test/java/org/cactoos/time/LocalDateTimeOfTest.java b/src/test/java/org/cactoos/time/LocalDateTimeOfTest.java index f30195820..6192206bb 100644 --- a/src/test/java/org/cactoos/time/LocalDateTimeOfTest.java +++ b/src/test/java/org/cactoos/time/LocalDateTimeOfTest.java @@ -33,7 +33,6 @@ * Tests for {@link LocalDateTimeOf}. * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") public class LocalDateTimeOfTest { diff --git a/src/test/java/org/cactoos/time/OffsetDateTimeOfTest.java b/src/test/java/org/cactoos/time/OffsetDateTimeOfTest.java index 20de22474..2ef4908d7 100644 --- a/src/test/java/org/cactoos/time/OffsetDateTimeOfTest.java +++ b/src/test/java/org/cactoos/time/OffsetDateTimeOfTest.java @@ -34,7 +34,6 @@ * Tests for {@link OffsetDateTimeOf}. * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") public class OffsetDateTimeOfTest { diff --git a/src/test/java/org/cactoos/time/ZonedDateTimeOfTest.java b/src/test/java/org/cactoos/time/ZonedDateTimeOfTest.java index 239ced14a..039f1ecfb 100644 --- a/src/test/java/org/cactoos/time/ZonedDateTimeOfTest.java +++ b/src/test/java/org/cactoos/time/ZonedDateTimeOfTest.java @@ -36,7 +36,6 @@ * Tests for {@link ZonedDateTimeOf}. * @since 1.0 * @checkstyle JavadocMethodCheck (500 lines) - * @checkstyle MagicNumberCheck (500 lines) */ @SuppressWarnings("PMD.AvoidDuplicateLiterals") public class ZonedDateTimeOfTest {