From b860d0ce3aae5d4875336e9cfa023ab73be24d7e Mon Sep 17 00:00:00 2001 From: Piyush Sagar Date: Tue, 27 Dec 2022 14:42:57 +0100 Subject: [PATCH] COLLECTIONS-806: Remove use of JUnit4 junit.framework.Test class (#371) * COLLECTIONS-806: removed references of JUnit4 Test class - Removed references of junit.framework.Test - Removed unused method BulkTest.makeSuite() * COLLECTIONS-806: removed unused imports --- .../commons/collections4/ArrayStackTest.java | 4 - .../apache/commons/collections4/BulkTest.java | 265 ------------------ .../commons/collections4/bag/HashBagTest.java | 6 - .../collections4/bag/PredicatedBagTest.java | 5 - .../bag/PredicatedSortedBagTest.java | 5 - .../collections4/bag/SynchronizedBagTest.java | 5 - .../collections4/bag/TransformedBagTest.java | 6 - .../bag/TransformedSortedBagTest.java | 6 - .../commons/collections4/bag/TreeBagTest.java | 5 - .../collections4/bag/UnmodifiableBagTest.java | 5 - .../bag/UnmodifiableSortedBagTest.java | 5 - .../bidimap/DualHashBidiMapTest.java | 5 - .../bidimap/DualLinkedHashBidiMapTest.java | 6 - .../bidimap/DualTreeBidiMap2Test.java | 5 - .../bidimap/DualTreeBidiMapTest.java | 6 - .../collections4/bidimap/TreeBidiMapTest.java | 5 - .../bidimap/UnmodifiableBidiMapTest.java | 5 - .../UnmodifiableOrderedBidiMapTest.java | 5 - .../UnmodifiableSortedBidiMapTest.java | 5 - .../AbstractNullComparatorTest.java | 9 - .../iterators/IteratorIterableTest.java | 4 - .../list/CursorableLinkedListTest.java | 6 - .../list/NodeCachingLinkedListTest.java | 5 - .../collections4/list/TreeListTest.java | 5 - .../map/CaseInsensitiveMapTest.java | 5 - .../map/FixedSizeSortedMapTest.java | 6 - .../collections4/map/Flat3MapTest.java | 4 - .../collections4/map/HashedMapTest.java | 5 - .../commons/collections4/map/LRUMapTest.java | 6 - .../collections4/map/LinkedMapTest.java | 4 - .../collections4/map/ListOrderedMap2Test.java | 4 - .../collections4/map/ListOrderedMapTest.java | 4 - .../collections4/map/MultiKeyMapTest.java | 5 - .../map/PassiveExpiringMapTest.java | 5 - .../map/ReferenceIdentityMapTest.java | 5 - .../collections4/map/ReferenceMapTest.java | 5 - .../collections4/map/SingletonMapTest.java | 5 - .../collections4/map/StaticBucketMapTest.java | 5 - .../map/TransformedSortedMapTest.java | 5 - .../multimap/ArrayListValuedHashMapTest.java | 5 - .../multimap/HashSetValuedHashMapTest.java | 5 - .../TransformedMultiValuedMapTest.java | 5 - .../UnmodifiableMultiValuedMapTest.java | 5 - .../multiset/HashMultiSetTest.java | 6 - .../multiset/PredicatedMultiSetTest.java | 5 - .../multiset/SynchronizedMultiSetTest.java | 6 - .../multiset/UnmodifiableMultiSetTest.java | 5 - .../queue/SynchronizedQueueTest.java | 4 - .../set/PredicatedNavigableSetTest.java | 5 - .../set/PredicatedSortedSetTest.java | 5 - .../set/TransformedNavigableSetTest.java | 5 - .../set/TransformedSortedSetTest.java | 5 - .../set/UnmodifiableNavigableSetTest.java | 5 - .../collections4/set/UnmodifiableSetTest.java | 5 - .../set/UnmodifiableSortedSetTest.java | 5 - .../collections4/trie/PatriciaTrie2Test.java | 5 - .../collections4/trie/PatriciaTrieTest.java | 5 - .../trie/UnmodifiableTrieTest.java | 5 - 58 files changed, 557 deletions(-) diff --git a/src/test/java/org/apache/commons/collections4/ArrayStackTest.java b/src/test/java/org/apache/commons/collections4/ArrayStackTest.java index cbb63f7e2..1d888b4ca 100644 --- a/src/test/java/org/apache/commons/collections4/ArrayStackTest.java +++ b/src/test/java/org/apache/commons/collections4/ArrayStackTest.java @@ -32,10 +32,6 @@ public class ArrayStackTest extends AbstractArrayListTest { super(ArrayStackTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(ArrayStackTest.class); - } - @Override public ArrayStack makeObject() { return new ArrayStack<>(); diff --git a/src/test/java/org/apache/commons/collections4/BulkTest.java b/src/test/java/org/apache/commons/collections4/BulkTest.java index bc3ddb44e..ba977cc9c 100644 --- a/src/test/java/org/apache/commons/collections4/BulkTest.java +++ b/src/test/java/org/apache/commons/collections4/BulkTest.java @@ -16,14 +16,6 @@ */ package org.apache.commons.collections4; -import java.lang.reflect.Constructor; -import java.lang.reflect.InvocationTargetException; -import java.lang.reflect.Method; -import java.lang.reflect.Modifier; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.List; - import junit.framework.TestCase; import junit.framework.TestSuite; @@ -233,261 +225,4 @@ public class BulkTest extends TestCase implements Cloneable { return getName() + "(" + verboseName + ") "; } - /** - * Returns a {@link TestSuite} for testing all of the simple tests - * and all the bulk tests defined by the given class.

- * - * The class is examined for simple and bulk test methods; any child - * bulk tests are also examined recursively; and the results are stored - * in a hierarchical {@link TestSuite}.

- * - * The given class must be a subclass of {@code BulkTest} and must - * not be abstract.

- * - * @param c the class to examine for simple and bulk tests - * @return a {@link TestSuite} containing all the simple and bulk tests - * defined by that class - */ - public static TestSuite makeSuite(final Class c) { - if (Modifier.isAbstract(c.getModifiers())) { - throw new IllegalArgumentException("Class must not be abstract."); - } - if (!BulkTest.class.isAssignableFrom(c)) { - throw new IllegalArgumentException("Class must extend BulkTest."); - } - return new BulkTestSuiteMaker(c).make(); - } - -} - -// It was easier to use a separate class to do all the reflection stuff -// for making the TestSuite instances. Having permanent state around makes -// it easier to handle the recursion. -class BulkTestSuiteMaker { - - /** The class that defines simple and bulk tests methods. */ - private final Class startingClass; - - /** List of ignored simple test names. */ - private List ignored; - - /** The TestSuite we're currently populating. Can change over time. */ - private TestSuite result; - - /** - * The prefix for simple test methods. Used to check if a test is in - * the ignored list. - */ - private String prefix; - - /** - * Constructor. - * - * @param startingClass the starting class - */ - BulkTestSuiteMaker(final Class startingClass) { - this.startingClass = startingClass; - } - - /** - * Makes a hierarchical TestSuite based on the starting class. - * - * @return the hierarchical TestSuite for startingClass - */ - public TestSuite make() { - this.result = new TestSuite(); - this.prefix = getBaseName(startingClass); - result.setName(prefix); - - final BulkTest bulk = makeFirstTestCase(startingClass); - ignored = new ArrayList<>(); - final String[] s = bulk.ignoredTests(); - if (s != null) { - ignored.addAll(Arrays.asList(s)); - } - make(bulk); - return result; - } - - /** - * Appends all the simple tests and bulk tests defined by the given - * instance's class to the current TestSuite. - * - * @param bulk An instance of the class that defines simple and bulk - * tests for us to append - */ - void make(final BulkTest bulk) { - final Class c = bulk.getClass(); - final Method[] all = c.getMethods(); - for (final Method element : all) { - if (isTest(element)) { - addTest(bulk, element); - } - if (isBulk(element)) { - addBulk(bulk, element); - } - } - } - - /** - * Adds the simple test defined by the given method to the TestSuite. - * - * @param bulk The instance of the class that defined the method - * (I know it's weird. But the point is, we can clone the instance - * and not have to worry about constructors.) - * @param m The simple test method - */ - void addTest(final BulkTest bulk, final Method m) { - final BulkTest bulk2 = (BulkTest) bulk.clone(); - bulk2.setName(m.getName()); - bulk2.verboseName = prefix + "." + m.getName(); - if (ignored.contains(bulk2.verboseName)) { - return; - } - result.addTest(bulk2); - } - - /** - * Adds a whole new suite of tests that are defined by the result of - * the given bulk test method. In other words, the given bulk test - * method is invoked, and the resulting BulkTest instance is examined - * for yet more simple and bulk tests. - * - * @param bulk The instance of the class that defined the method - * @param m The bulk test method - */ - void addBulk(final BulkTest bulk, final Method m) { - final String verboseName = prefix + "." + m.getName(); - if (ignored.contains(verboseName)) { - return; - } - - final BulkTest bulk2; - try { - bulk2 = (BulkTest) m.invoke(bulk, (Object[]) null); - if (bulk2 == null) { - return; - } - } catch (final InvocationTargetException ex) { - ex.getTargetException().printStackTrace(); - throw new Error(); // FIXME; - } catch (final IllegalAccessException ex) { - ex.printStackTrace(); - throw new Error(); // FIXME; - } - - // Save current state on the stack. - final String oldPrefix = prefix; - final TestSuite oldResult = result; - - prefix = prefix + "." + m.getName(); - result = new TestSuite(); - result.setName(m.getName()); - - make(bulk2); - - oldResult.addTest(result); - - // Restore the old state - prefix = oldPrefix; - result = oldResult; - } - - /** - * Returns the base name of the given class. - * - * @param c the class - * @return the name of that class, minus any package names - */ - private static String getBaseName(final Class c) { - String name = c.getName(); - final int p = name.lastIndexOf('.'); - if (p > 0) { - name = name.substring(p + 1); - } - return name; - } - - - // These three methods are used to create a valid BulkTest instance - // from a class. - - private static Constructor getTestCaseConstructor(final Class c) { - try { - return c.getConstructor(); - } catch (final NoSuchMethodException e) { - throw new IllegalArgumentException(c + " must provide an empty constructor"); - } - } - - private static BulkTest makeTestCase(final Class c, final Method m) { - final Constructor con = getTestCaseConstructor(c); - try { - return con.newInstance(); - } catch (final InvocationTargetException e) { - e.printStackTrace(); - throw new RuntimeException(); // FIXME; - } catch (final IllegalAccessException e) { - throw new Error(); // should never occur - } catch (final InstantiationException e) { - throw new RuntimeException(); // FIXME; - } - } - - private static BulkTest makeFirstTestCase(final Class c) { - final Method[] all = c.getMethods(); - for (final Method element : all) { - if (isTest(element)) { - return makeTestCase(c, element); - } - } - throw new IllegalArgumentException(c.getName() + " must provide at least one test method."); - } - - /** - * Returns true if the given method is a simple test method. - */ - private static boolean isTest(final Method m) { - if (!m.getName().startsWith("test")) { - return false; - } - if (m.getReturnType() != Void.TYPE) { - return false; - } - if (m.getParameterTypes().length != 0) { - return false; - } - final int mods = m.getModifiers(); - if (Modifier.isStatic(mods)) { - return false; - } - if (Modifier.isAbstract(mods)) { - return false; - } - return true; - } - - /** - * Returns true if the given method is a bulk test method. - */ - private static boolean isBulk(final Method m) { - if (!m.getName().startsWith("bulkTest")) { - return false; - } - if (m.getReturnType() != BulkTest.class) { - return false; - } - if (m.getParameterTypes().length != 0) { - return false; - } - final int mods = m.getModifiers(); - if (Modifier.isStatic(mods)) { - return false; - } - if (Modifier.isAbstract(mods)) { - return false; - } - return true; - } - } diff --git a/src/test/java/org/apache/commons/collections4/bag/HashBagTest.java b/src/test/java/org/apache/commons/collections4/bag/HashBagTest.java index b1639b83c..5c7fd7174 100644 --- a/src/test/java/org/apache/commons/collections4/bag/HashBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/HashBagTest.java @@ -17,7 +17,6 @@ package org.apache.commons.collections4.bag; import org.apache.commons.collections4.Bag; -import org.apache.commons.collections4.BulkTest; /** * Extension of {@link AbstractBagTest} for exercising the {@link HashBag} @@ -30,11 +29,6 @@ public class HashBagTest extends AbstractBagTest { super(HashBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(HashBagTest.class); - } - - @Override public Bag makeObject() { return new HashBag<>(); diff --git a/src/test/java/org/apache/commons/collections4/bag/PredicatedBagTest.java b/src/test/java/org/apache/commons/collections4/bag/PredicatedBagTest.java index 908bb42de..48b55e403 100644 --- a/src/test/java/org/apache/commons/collections4/bag/PredicatedBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/PredicatedBagTest.java @@ -21,7 +21,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Set; import org.apache.commons.collections4.Bag; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Predicate; import org.apache.commons.collections4.functors.TruePredicate; import org.junit.jupiter.api.Test; @@ -38,10 +37,6 @@ public class PredicatedBagTest extends AbstractBagTest { super(PredicatedBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PredicatedBagTest.class); - } - protected Predicate stringPredicate() { return o -> o instanceof String; } diff --git a/src/test/java/org/apache/commons/collections4/bag/PredicatedSortedBagTest.java b/src/test/java/org/apache/commons/collections4/bag/PredicatedSortedBagTest.java index f0e4aacb3..8be659abf 100644 --- a/src/test/java/org/apache/commons/collections4/bag/PredicatedSortedBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/PredicatedSortedBagTest.java @@ -20,7 +20,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Comparator; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Predicate; import org.apache.commons.collections4.SortedBag; import org.apache.commons.collections4.functors.TruePredicate; @@ -40,10 +39,6 @@ public class PredicatedSortedBagTest extends AbstractSortedBagTest { super(PredicatedSortedBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PredicatedSortedBagTest.class); - } - protected Predicate stringPredicate() { return o -> o instanceof String; } diff --git a/src/test/java/org/apache/commons/collections4/bag/SynchronizedBagTest.java b/src/test/java/org/apache/commons/collections4/bag/SynchronizedBagTest.java index e01b2d56e..20a14a875 100644 --- a/src/test/java/org/apache/commons/collections4/bag/SynchronizedBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/SynchronizedBagTest.java @@ -17,7 +17,6 @@ package org.apache.commons.collections4.bag; import org.apache.commons.collections4.Bag; -import org.apache.commons.collections4.BulkTest; /** * Extension of {@link AbstractBagTest} for exercising the {@link SynchronizedBag} @@ -31,10 +30,6 @@ public class SynchronizedBagTest extends AbstractBagTest { super(SynchronizedBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(SynchronizedBagTest.class); - } - @Override public Bag makeObject() { diff --git a/src/test/java/org/apache/commons/collections4/bag/TransformedBagTest.java b/src/test/java/org/apache/commons/collections4/bag/TransformedBagTest.java index cff890f58..465062708 100644 --- a/src/test/java/org/apache/commons/collections4/bag/TransformedBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/TransformedBagTest.java @@ -17,7 +17,6 @@ package org.apache.commons.collections4.bag; import org.apache.commons.collections4.Bag; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Transformer; import org.apache.commons.collections4.collection.TransformedCollectionTest; import org.junit.jupiter.api.Test; @@ -34,11 +33,6 @@ public class TransformedBagTest extends AbstractBagTest { super(TransformedBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TransformedBagTest.class); - } - - @Override @SuppressWarnings("unchecked") public Bag makeObject() { diff --git a/src/test/java/org/apache/commons/collections4/bag/TransformedSortedBagTest.java b/src/test/java/org/apache/commons/collections4/bag/TransformedSortedBagTest.java index 414d7fb8c..8b1eb4e77 100644 --- a/src/test/java/org/apache/commons/collections4/bag/TransformedSortedBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/TransformedSortedBagTest.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.bag; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.SortedBag; import org.apache.commons.collections4.Transformer; import org.apache.commons.collections4.collection.TransformedCollectionTest; @@ -34,11 +33,6 @@ public class TransformedSortedBagTest extends AbstractSortedBagTest { super(TransformedSortedBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TransformedSortedBagTest.class); - } - - @Override @SuppressWarnings("unchecked") public SortedBag makeObject() { diff --git a/src/test/java/org/apache/commons/collections4/bag/TreeBagTest.java b/src/test/java/org/apache/commons/collections4/bag/TreeBagTest.java index e6230ba6f..5c269ecc1 100644 --- a/src/test/java/org/apache/commons/collections4/bag/TreeBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/TreeBagTest.java @@ -19,7 +19,6 @@ package org.apache.commons.collections4.bag; import static org.junit.jupiter.api.Assertions.assertThrows; import org.apache.commons.collections4.Bag; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.SortedBag; import org.junit.jupiter.api.Test; @@ -33,10 +32,6 @@ public class TreeBagTest extends AbstractSortedBagTest { super(TreeBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TreeBagTest.class); - } - @Override public SortedBag makeObject() { return new TreeBag<>(); diff --git a/src/test/java/org/apache/commons/collections4/bag/UnmodifiableBagTest.java b/src/test/java/org/apache/commons/collections4/bag/UnmodifiableBagTest.java index 2d8369a8b..34f695e3f 100644 --- a/src/test/java/org/apache/commons/collections4/bag/UnmodifiableBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/UnmodifiableBagTest.java @@ -21,7 +21,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Arrays; import org.apache.commons.collections4.Bag; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Unmodifiable; import org.apache.commons.collections4.collection.AbstractCollectionTest; import org.junit.jupiter.api.Test; @@ -38,10 +37,6 @@ public class UnmodifiableBagTest extends AbstractBagTest { super(UnmodifiableBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableBagTest.class); - } - @Override public Bag makeObject() { return UnmodifiableBag.unmodifiableBag(new HashBag()); diff --git a/src/test/java/org/apache/commons/collections4/bag/UnmodifiableSortedBagTest.java b/src/test/java/org/apache/commons/collections4/bag/UnmodifiableSortedBagTest.java index 3206fd415..d04f7d595 100644 --- a/src/test/java/org/apache/commons/collections4/bag/UnmodifiableSortedBagTest.java +++ b/src/test/java/org/apache/commons/collections4/bag/UnmodifiableSortedBagTest.java @@ -20,7 +20,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Arrays; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.SortedBag; import org.apache.commons.collections4.Unmodifiable; import org.apache.commons.collections4.collection.AbstractCollectionTest; @@ -38,10 +37,6 @@ public class UnmodifiableSortedBagTest extends AbstractSortedBagTest { super(UnmodifiableSortedBagTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableSortedBagTest.class); - } - @Override public SortedBag makeObject() { return UnmodifiableSortedBag.unmodifiableSortedBag(new TreeBag()); diff --git a/src/test/java/org/apache/commons/collections4/bidimap/DualHashBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/DualHashBidiMapTest.java index 219adde03..dea648309 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/DualHashBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/DualHashBidiMapTest.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.bidimap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.collection.AbstractCollectionTest; /** @@ -24,10 +23,6 @@ import org.apache.commons.collections4.collection.AbstractCollectionTest; */ public class DualHashBidiMapTest extends AbstractBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(DualHashBidiMapTest.class); - } - public DualHashBidiMapTest() { super(DualHashBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/DualLinkedHashBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/DualLinkedHashBidiMapTest.java index d51105e5a..629f8d47a 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/DualLinkedHashBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/DualLinkedHashBidiMapTest.java @@ -16,18 +16,12 @@ */ package org.apache.commons.collections4.bidimap; -import org.apache.commons.collections4.BulkTest; - /** * JUnit tests. * */ public class DualLinkedHashBidiMapTest extends AbstractBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(DualLinkedHashBidiMapTest.class); - } - public DualLinkedHashBidiMapTest() { super(DualLinkedHashBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMap2Test.java b/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMap2Test.java index 7b64e4460..ebef9d0b0 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMap2Test.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMap2Test.java @@ -27,7 +27,6 @@ import java.util.Iterator; import java.util.List; import java.util.TreeMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.SortedBidiMap; import org.apache.commons.collections4.comparators.ComparableComparator; import org.apache.commons.collections4.comparators.ReverseComparator; @@ -40,10 +39,6 @@ import org.junit.jupiter.api.Test; @SuppressWarnings("boxing") public class DualTreeBidiMap2Test, V extends Comparable> extends AbstractSortedBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(DualTreeBidiMap2Test.class); - } - public DualTreeBidiMap2Test() { super(DualTreeBidiMap2Test.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMapTest.java index cf5cc42fa..e301ce263 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/DualTreeBidiMapTest.java @@ -16,18 +16,12 @@ */ package org.apache.commons.collections4.bidimap; -import org.apache.commons.collections4.BulkTest; - /** * JUnit tests. * */ public class DualTreeBidiMapTest, V extends Comparable> extends AbstractSortedBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(DualTreeBidiMapTest.class); - } - public DualTreeBidiMapTest() { super(DualTreeBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/TreeBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/TreeBidiMapTest.java index 8f8a6ad5b..590f3db18 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/TreeBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/TreeBidiMapTest.java @@ -19,7 +19,6 @@ package org.apache.commons.collections4.bidimap; import java.util.TreeMap; import org.apache.commons.collections4.BidiMap; -import org.apache.commons.collections4.BulkTest; /** * JUnit tests. @@ -27,10 +26,6 @@ import org.apache.commons.collections4.BulkTest; */ public class TreeBidiMapTest, V extends Comparable> extends AbstractOrderedBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TreeBidiMapTest.class); - } - public TreeBidiMapTest() { super(TreeBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableBidiMapTest.java index 8950b5a98..84feb1d85 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableBidiMapTest.java @@ -22,7 +22,6 @@ import java.util.HashMap; import java.util.Map; import org.apache.commons.collections4.BidiMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Unmodifiable; import org.apache.commons.collections4.collection.AbstractCollectionTest; import org.junit.jupiter.api.Test; @@ -32,10 +31,6 @@ import org.junit.jupiter.api.Test; */ public class UnmodifiableBidiMapTest extends AbstractBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableBidiMapTest.class); - } - public UnmodifiableBidiMapTest() { super(UnmodifiableBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableOrderedBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableOrderedBidiMapTest.java index 7a3dade70..760fcc378 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableOrderedBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableOrderedBidiMapTest.java @@ -21,7 +21,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Map; import java.util.TreeMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.OrderedBidiMap; import org.apache.commons.collections4.Unmodifiable; import org.junit.jupiter.api.Test; @@ -31,10 +30,6 @@ import org.junit.jupiter.api.Test; */ public class UnmodifiableOrderedBidiMapTest, V extends Comparable> extends AbstractOrderedBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableOrderedBidiMapTest.class); - } - public UnmodifiableOrderedBidiMapTest() { super(UnmodifiableOrderedBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableSortedBidiMapTest.java b/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableSortedBidiMapTest.java index f4e100563..e89370eeb 100644 --- a/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableSortedBidiMapTest.java +++ b/src/test/java/org/apache/commons/collections4/bidimap/UnmodifiableSortedBidiMapTest.java @@ -21,7 +21,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.SortedMap; import java.util.TreeMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.SortedBidiMap; import org.apache.commons.collections4.Unmodifiable; import org.junit.jupiter.api.Test; @@ -31,10 +30,6 @@ import org.junit.jupiter.api.Test; */ public class UnmodifiableSortedBidiMapTest, V extends Comparable> extends AbstractSortedBidiMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableSortedBidiMapTest.class); - } - public UnmodifiableSortedBidiMapTest() { super(UnmodifiableSortedBidiMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/comparators/AbstractNullComparatorTest.java b/src/test/java/org/apache/commons/collections4/comparators/AbstractNullComparatorTest.java index 07014a7e7..3f46b0572 100644 --- a/src/test/java/org/apache/commons/collections4/comparators/AbstractNullComparatorTest.java +++ b/src/test/java/org/apache/commons/collections4/comparators/AbstractNullComparatorTest.java @@ -20,8 +20,6 @@ import java.util.Comparator; import java.util.LinkedList; import java.util.List; -import junit.framework.TestSuite; - /** * Test the NullComparator. * @@ -32,13 +30,6 @@ public abstract class AbstractNullComparatorTest extends AbstractComparatorTest< super(testName); } - public static junit.framework.Test suite() { - final TestSuite suite = new TestSuite(AbstractNullComparatorTest.class.getName()); - suite.addTest(new TestSuite(TestNullComparator1.class)); - suite.addTest(new TestSuite(TestNullComparator2.class)); - return suite; - } - /** * Test the NullComparator with nulls high, using comparable comparator **/ diff --git a/src/test/java/org/apache/commons/collections4/iterators/IteratorIterableTest.java b/src/test/java/org/apache/commons/collections4/iterators/IteratorIterableTest.java index 06c2637f4..e37309a77 100644 --- a/src/test/java/org/apache/commons/collections4/iterators/IteratorIterableTest.java +++ b/src/test/java/org/apache/commons/collections4/iterators/IteratorIterableTest.java @@ -29,10 +29,6 @@ import org.junit.jupiter.api.Test; */ public class IteratorIterableTest extends BulkTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(IteratorIterableTest.class); - } - public IteratorIterableTest() { super(IteratorIterableTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/list/CursorableLinkedListTest.java b/src/test/java/org/apache/commons/collections4/list/CursorableLinkedListTest.java index e81d37dba..2cc1f53d6 100644 --- a/src/test/java/org/apache/commons/collections4/list/CursorableLinkedListTest.java +++ b/src/test/java/org/apache/commons/collections4/list/CursorableLinkedListTest.java @@ -28,7 +28,6 @@ import java.util.List; import java.util.ListIterator; import java.util.NoSuchElementException; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.lang3.ArrayUtils; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; @@ -41,11 +40,6 @@ public class CursorableLinkedListTest extends AbstractLinkedListTest { public CursorableLinkedListTest() { super(CursorableLinkedListTest.class.getSimpleName()); } - - public static junit.framework.Test suite() { - return BulkTest.makeSuite(CursorableLinkedListTest.class); - } - private CursorableLinkedList list; @Override diff --git a/src/test/java/org/apache/commons/collections4/list/NodeCachingLinkedListTest.java b/src/test/java/org/apache/commons/collections4/list/NodeCachingLinkedListTest.java index 952ca61e0..182ca6a36 100644 --- a/src/test/java/org/apache/commons/collections4/list/NodeCachingLinkedListTest.java +++ b/src/test/java/org/apache/commons/collections4/list/NodeCachingLinkedListTest.java @@ -19,7 +19,6 @@ package org.apache.commons.collections4.list; import java.util.Arrays; import java.util.LinkedList; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -32,10 +31,6 @@ public class NodeCachingLinkedListTest extends AbstractLinkedListTest { super(NodeCachingLinkedListTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(NodeCachingLinkedListTest.class); - } - @Override public NodeCachingLinkedList makeObject() { return new NodeCachingLinkedList<>(); diff --git a/src/test/java/org/apache/commons/collections4/list/TreeListTest.java b/src/test/java/org/apache/commons/collections4/list/TreeListTest.java index a18ebcbc4..89ba587ed 100644 --- a/src/test/java/org/apache/commons/collections4/list/TreeListTest.java +++ b/src/test/java/org/apache/commons/collections4/list/TreeListTest.java @@ -20,7 +20,6 @@ import java.util.ArrayList; import java.util.List; import java.util.ListIterator; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -47,10 +46,6 @@ public class TreeListTest extends AbstractListTest { // benchmark(new NodeCachingLinkedList()); // } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TreeListTest.class); - } - public static void benchmark(final List l) { long startMillis = System.currentTimeMillis(); for (int i = 0; i < 100000; i++) { diff --git a/src/test/java/org/apache/commons/collections4/map/CaseInsensitiveMapTest.java b/src/test/java/org/apache/commons/collections4/map/CaseInsensitiveMapTest.java index 7201ea798..13d503b3e 100644 --- a/src/test/java/org/apache/commons/collections4/map/CaseInsensitiveMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/CaseInsensitiveMapTest.java @@ -21,7 +21,6 @@ import java.util.Locale; import java.util.Map; import java.util.Set; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -30,10 +29,6 @@ import org.junit.jupiter.api.Test; */ public class CaseInsensitiveMapTest extends AbstractIterableMapTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(CaseInsensitiveMapTest.class); - } - public CaseInsensitiveMapTest() { super(CaseInsensitiveMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/map/FixedSizeSortedMapTest.java b/src/test/java/org/apache/commons/collections4/map/FixedSizeSortedMapTest.java index 1a4bcaabb..9597a107e 100644 --- a/src/test/java/org/apache/commons/collections4/map/FixedSizeSortedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/FixedSizeSortedMapTest.java @@ -19,8 +19,6 @@ package org.apache.commons.collections4.map; import java.util.SortedMap; import java.util.TreeMap; -import org.apache.commons.collections4.BulkTest; - /** * Extension of {@link AbstractSortedMapTest} for exercising the {@link FixedSizeSortedMap} * implementation. @@ -33,10 +31,6 @@ public class FixedSizeSortedMapTest extends AbstractSortedMapTest { super(FixedSizeSortedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(FixedSizeSortedMapTest.class); - } - @Override public SortedMap makeObject() { return FixedSizeSortedMap.fixedSizeSortedMap(new TreeMap()); diff --git a/src/test/java/org/apache/commons/collections4/map/Flat3MapTest.java b/src/test/java/org/apache/commons/collections4/map/Flat3MapTest.java index 2b7cfe412..7e5753911 100644 --- a/src/test/java/org/apache/commons/collections4/map/Flat3MapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/Flat3MapTest.java @@ -48,10 +48,6 @@ public class Flat3MapTest extends AbstractIterableMapTest { super(Flat3MapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(Flat3MapTest.class); - } - @Override public Flat3Map makeObject() { return new Flat3Map<>(); diff --git a/src/test/java/org/apache/commons/collections4/map/HashedMapTest.java b/src/test/java/org/apache/commons/collections4/map/HashedMapTest.java index 6ecb50534..47bde7428 100644 --- a/src/test/java/org/apache/commons/collections4/map/HashedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/HashedMapTest.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.map; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -29,10 +28,6 @@ public class HashedMapTest extends AbstractIterableMapTest { super(HashedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(HashedMapTest.class); - } - @Override public HashedMap makeObject() { return new HashedMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/map/LRUMapTest.java b/src/test/java/org/apache/commons/collections4/map/LRUMapTest.java index 374350e78..835de5e8c 100644 --- a/src/test/java/org/apache/commons/collections4/map/LRUMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/LRUMapTest.java @@ -25,7 +25,6 @@ import java.util.Iterator; import java.util.List; import java.util.Map; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MapIterator; import org.apache.commons.collections4.OrderedMap; import org.apache.commons.collections4.ResettableIterator; @@ -39,11 +38,6 @@ public class LRUMapTest extends AbstractOrderedMapTest { public LRUMapTest() { super(LRUMapTest.class.getSimpleName()); } - - public static junit.framework.Test suite() { - return BulkTest.makeSuite(LRUMapTest.class); - } - @Override public LRUMap makeObject() { return new LRUMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/map/LinkedMapTest.java b/src/test/java/org/apache/commons/collections4/map/LinkedMapTest.java index f492fb97a..37baa4758 100644 --- a/src/test/java/org/apache/commons/collections4/map/LinkedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/LinkedMapTest.java @@ -38,10 +38,6 @@ public class LinkedMapTest extends AbstractOrderedMapTest { super(LinkedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(LinkedMapTest.class); - } - @Override public LinkedMap makeObject() { return new LinkedMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/map/ListOrderedMap2Test.java b/src/test/java/org/apache/commons/collections4/map/ListOrderedMap2Test.java index a8c33122b..90ab9a702 100644 --- a/src/test/java/org/apache/commons/collections4/map/ListOrderedMap2Test.java +++ b/src/test/java/org/apache/commons/collections4/map/ListOrderedMap2Test.java @@ -36,10 +36,6 @@ public class ListOrderedMap2Test extends AbstractOrderedMapTest { super(ListOrderedMap2Test.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(ListOrderedMap2Test.class); - } - @Override public ListOrderedMap makeObject() { return new ListOrderedMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/map/ListOrderedMapTest.java b/src/test/java/org/apache/commons/collections4/map/ListOrderedMapTest.java index d5cbe4aac..6141004b3 100644 --- a/src/test/java/org/apache/commons/collections4/map/ListOrderedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/ListOrderedMapTest.java @@ -42,10 +42,6 @@ public class ListOrderedMapTest extends AbstractOrderedMapTest { super(ListOrderedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(ListOrderedMapTest.class); - } - @Override public ListOrderedMap makeObject() { return ListOrderedMap.listOrderedMap(new HashMap()); diff --git a/src/test/java/org/apache/commons/collections4/map/MultiKeyMapTest.java b/src/test/java/org/apache/commons/collections4/map/MultiKeyMapTest.java index d1ff50423..63e728d8f 100644 --- a/src/test/java/org/apache/commons/collections4/map/MultiKeyMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/MultiKeyMapTest.java @@ -20,7 +20,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Map; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MapIterator; import org.apache.commons.collections4.keyvalue.MultiKey; import org.junit.jupiter.api.Test; @@ -43,10 +42,6 @@ public class MultiKeyMapTest extends AbstractIterableMapTest makeObject() { return new MultiKeyMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/map/PassiveExpiringMapTest.java b/src/test/java/org/apache/commons/collections4/map/PassiveExpiringMapTest.java index 62e98fc89..ae6599187 100644 --- a/src/test/java/org/apache/commons/collections4/map/PassiveExpiringMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/PassiveExpiringMapTest.java @@ -23,7 +23,6 @@ import java.util.HashMap; import java.util.Map; import java.util.concurrent.TimeUnit; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.collection.AbstractCollectionTest; import org.apache.commons.collections4.map.PassiveExpiringMap.ExpirationPolicy; import org.junit.jupiter.api.Test; @@ -55,10 +54,6 @@ public class PassiveExpiringMapTest extends AbstractMapTest { } } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PassiveExpiringMapTest.class); - } - public PassiveExpiringMapTest() { super(PassiveExpiringMapTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/map/ReferenceIdentityMapTest.java b/src/test/java/org/apache/commons/collections4/map/ReferenceIdentityMapTest.java index ea0d15610..a0d5bc09a 100644 --- a/src/test/java/org/apache/commons/collections4/map/ReferenceIdentityMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/ReferenceIdentityMapTest.java @@ -22,7 +22,6 @@ import java.lang.ref.WeakReference; import java.util.Iterator; import java.util.Map; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.IterableMap; import org.apache.commons.collections4.map.AbstractReferenceMap.ReferenceStrength; import org.junit.jupiter.api.Test; @@ -48,10 +47,6 @@ public class ReferenceIdentityMapTest extends AbstractIterableMapTest keyReference; WeakReference valueReference; diff --git a/src/test/java/org/apache/commons/collections4/map/ReferenceMapTest.java b/src/test/java/org/apache/commons/collections4/map/ReferenceMapTest.java index 62e172b44..7110640c1 100644 --- a/src/test/java/org/apache/commons/collections4/map/ReferenceMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/ReferenceMapTest.java @@ -31,7 +31,6 @@ import java.util.List; import java.util.Map; import java.util.function.Consumer; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.map.AbstractHashedMap.HashEntry; import org.apache.commons.collections4.map.AbstractReferenceMap.ReferenceEntry; import org.apache.commons.collections4.map.AbstractReferenceMap.ReferenceStrength; @@ -46,10 +45,6 @@ public class ReferenceMapTest extends AbstractIterableMapTest { super(ReferenceMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(ReferenceMapTest.class); - } - @Override public ReferenceMap makeObject() { return new ReferenceMap<>(ReferenceStrength.WEAK, ReferenceStrength.WEAK); diff --git a/src/test/java/org/apache/commons/collections4/map/SingletonMapTest.java b/src/test/java/org/apache/commons/collections4/map/SingletonMapTest.java index 2420255ed..64c11aec6 100644 --- a/src/test/java/org/apache/commons/collections4/map/SingletonMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/SingletonMapTest.java @@ -19,7 +19,6 @@ package org.apache.commons.collections4.map; import java.util.HashMap; import org.apache.commons.collections4.BoundedMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.KeyValue; import org.apache.commons.collections4.OrderedMap; import org.junit.jupiter.api.Test; @@ -38,10 +37,6 @@ public class SingletonMapTest extends AbstractOrderedMapTest { super(SingletonMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(SingletonMapTest.class); - } - @Override public OrderedMap makeObject() { // need an empty singleton map, but that's not possible diff --git a/src/test/java/org/apache/commons/collections4/map/StaticBucketMapTest.java b/src/test/java/org/apache/commons/collections4/map/StaticBucketMapTest.java index 1b5ff638e..31bc6eb90 100644 --- a/src/test/java/org/apache/commons/collections4/map/StaticBucketMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/StaticBucketMapTest.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.map; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -30,10 +29,6 @@ public class StaticBucketMapTest extends AbstractIterableMapTest { super(StaticBucketMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(StaticBucketMapTest.class); - } - @Override public StaticBucketMap makeObject() { return new StaticBucketMap<>(30); diff --git a/src/test/java/org/apache/commons/collections4/map/TransformedSortedMapTest.java b/src/test/java/org/apache/commons/collections4/map/TransformedSortedMapTest.java index 674fe608c..972bb9fb6 100644 --- a/src/test/java/org/apache/commons/collections4/map/TransformedSortedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/map/TransformedSortedMapTest.java @@ -23,7 +23,6 @@ import java.util.Set; import java.util.SortedMap; import java.util.TreeMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Transformer; import org.apache.commons.collections4.TransformerUtils; import org.apache.commons.collections4.collection.TransformedCollectionTest; @@ -41,10 +40,6 @@ public class TransformedSortedMapTest extends AbstractSortedMapTest super(TransformedSortedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TransformedSortedMapTest.class); - } - @Override public String[] ignoredTests() { return null; diff --git a/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java b/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java index 5119380a9..fb4209555 100644 --- a/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java +++ b/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java @@ -23,7 +23,6 @@ import java.util.List; import java.util.ListIterator; import java.util.Map; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.ListValuedMap; import org.apache.commons.collections4.MultiValuedMap; import org.apache.commons.collections4.collection.AbstractCollectionTest; @@ -40,10 +39,6 @@ public class ArrayListValuedHashMapTest extends AbstractMultiValuedMapTest super(ArrayListValuedHashMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(ArrayListValuedHashMapTest.class); - } - @Override public ListValuedMap makeObject() { return new ArrayListValuedHashMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java b/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java index 0c4f3d9c1..7501cad64 100644 --- a/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java +++ b/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java @@ -21,7 +21,6 @@ import java.util.Iterator; import java.util.Map; import java.util.Set; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiValuedMap; import org.apache.commons.collections4.SetValuedMap; import org.apache.commons.collections4.collection.AbstractCollectionTest; @@ -38,10 +37,6 @@ public class HashSetValuedHashMapTest extends AbstractMultiValuedMapTest makeObject() { return new HashSetValuedHashMap<>(); diff --git a/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java b/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java index 7995bd6e0..4560f81b5 100644 --- a/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java @@ -18,7 +18,6 @@ package org.apache.commons.collections4.multimap; import java.util.Collection; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiValuedMap; import org.apache.commons.collections4.Transformer; import org.apache.commons.collections4.TransformerUtils; @@ -37,10 +36,6 @@ public class TransformedMultiValuedMapTest extends AbstractMultiValuedMapT super(TransformedMultiValuedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TransformedMultiValuedMapTest.class); - } - @Override public MultiValuedMap makeObject() { return TransformedMultiValuedMap.transformingMap(new ArrayListValuedHashMap(), diff --git a/src/test/java/org/apache/commons/collections4/multimap/UnmodifiableMultiValuedMapTest.java b/src/test/java/org/apache/commons/collections4/multimap/UnmodifiableMultiValuedMapTest.java index 3238a9539..2d44ba1fe 100644 --- a/src/test/java/org/apache/commons/collections4/multimap/UnmodifiableMultiValuedMapTest.java +++ b/src/test/java/org/apache/commons/collections4/multimap/UnmodifiableMultiValuedMapTest.java @@ -26,7 +26,6 @@ import java.util.Map; import java.util.Map.Entry; import java.util.Set; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MapIterator; import org.apache.commons.collections4.MultiSet; import org.apache.commons.collections4.MultiValuedMap; @@ -45,10 +44,6 @@ public class UnmodifiableMultiValuedMapTest extends AbstractMultiValuedMap super(UnmodifiableMultiValuedMapTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableMultiValuedMapTest.class); - } - /** * Assert the given map contains all added values after it was initialized * with makeFullMap(). See COLLECTIONS-769. diff --git a/src/test/java/org/apache/commons/collections4/multiset/HashMultiSetTest.java b/src/test/java/org/apache/commons/collections4/multiset/HashMultiSetTest.java index 65c09246e..6ef0a188d 100644 --- a/src/test/java/org/apache/commons/collections4/multiset/HashMultiSetTest.java +++ b/src/test/java/org/apache/commons/collections4/multiset/HashMultiSetTest.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.multiset; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiSet; /** @@ -31,11 +30,6 @@ public class HashMultiSetTest extends AbstractMultiSetTest { super(HashMultiSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(HashMultiSetTest.class); - } - - @Override public MultiSet makeObject() { return new HashMultiSet<>(); diff --git a/src/test/java/org/apache/commons/collections4/multiset/PredicatedMultiSetTest.java b/src/test/java/org/apache/commons/collections4/multiset/PredicatedMultiSetTest.java index c2aa7aa8e..9faebc34c 100644 --- a/src/test/java/org/apache/commons/collections4/multiset/PredicatedMultiSetTest.java +++ b/src/test/java/org/apache/commons/collections4/multiset/PredicatedMultiSetTest.java @@ -20,7 +20,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Set; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiSet; import org.apache.commons.collections4.Predicate; import org.apache.commons.collections4.functors.TruePredicate; @@ -38,10 +37,6 @@ public class PredicatedMultiSetTest extends AbstractMultiSetTest { super(PredicatedMultiSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PredicatedMultiSetTest.class); - } - protected Predicate stringPredicate() { return o -> o instanceof String; } diff --git a/src/test/java/org/apache/commons/collections4/multiset/SynchronizedMultiSetTest.java b/src/test/java/org/apache/commons/collections4/multiset/SynchronizedMultiSetTest.java index 605251780..1349aab93 100644 --- a/src/test/java/org/apache/commons/collections4/multiset/SynchronizedMultiSetTest.java +++ b/src/test/java/org/apache/commons/collections4/multiset/SynchronizedMultiSetTest.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.multiset; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiSet; /** @@ -31,11 +30,6 @@ public class SynchronizedMultiSetTest extends AbstractMultiSetTest { super(SynchronizedMultiSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(SynchronizedMultiSetTest.class); - } - - @Override public MultiSet makeObject() { return SynchronizedMultiSet.synchronizedMultiSet(new HashMultiSet()); diff --git a/src/test/java/org/apache/commons/collections4/multiset/UnmodifiableMultiSetTest.java b/src/test/java/org/apache/commons/collections4/multiset/UnmodifiableMultiSetTest.java index 45029f583..3862eb988 100644 --- a/src/test/java/org/apache/commons/collections4/multiset/UnmodifiableMultiSetTest.java +++ b/src/test/java/org/apache/commons/collections4/multiset/UnmodifiableMultiSetTest.java @@ -20,7 +20,6 @@ import static org.junit.jupiter.api.Assertions.assertThrows; import java.util.Arrays; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiSet; import org.apache.commons.collections4.Unmodifiable; import org.junit.jupiter.api.Test; @@ -37,10 +36,6 @@ public class UnmodifiableMultiSetTest extends AbstractMultiSetTest { super(UnmodifiableMultiSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableMultiSetTest.class); - } - @Override public MultiSet makeObject() { return UnmodifiableMultiSet.unmodifiableMultiSet(new HashMultiSet()); diff --git a/src/test/java/org/apache/commons/collections4/queue/SynchronizedQueueTest.java b/src/test/java/org/apache/commons/collections4/queue/SynchronizedQueueTest.java index 824b1803b..00b790461 100644 --- a/src/test/java/org/apache/commons/collections4/queue/SynchronizedQueueTest.java +++ b/src/test/java/org/apache/commons/collections4/queue/SynchronizedQueueTest.java @@ -30,10 +30,6 @@ import org.junit.jupiter.api.Test; */ public class SynchronizedQueueTest extends AbstractQueueTest { - public static junit.framework.Test suite() { - return BulkTest.makeSuite(SynchronizedQueueTest.class); - } - public SynchronizedQueueTest() { super(SynchronizedQueueTest.class.getSimpleName()); } diff --git a/src/test/java/org/apache/commons/collections4/set/PredicatedNavigableSetTest.java b/src/test/java/org/apache/commons/collections4/set/PredicatedNavigableSetTest.java index 27cf16449..51330f971 100644 --- a/src/test/java/org/apache/commons/collections4/set/PredicatedNavigableSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/PredicatedNavigableSetTest.java @@ -24,7 +24,6 @@ import java.util.NavigableSet; import java.util.Set; import java.util.TreeSet; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Predicate; import org.apache.commons.collections4.functors.TruePredicate; import org.junit.jupiter.api.Test; @@ -41,10 +40,6 @@ public class PredicatedNavigableSetTest extends AbstractNavigableSetTest { super(PredicatedNavigableSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PredicatedNavigableSetTest.class); - } - protected Predicate truePredicate = TruePredicate.truePredicate(); @Override diff --git a/src/test/java/org/apache/commons/collections4/set/PredicatedSortedSetTest.java b/src/test/java/org/apache/commons/collections4/set/PredicatedSortedSetTest.java index ebc84e8da..e1c6a07a2 100644 --- a/src/test/java/org/apache/commons/collections4/set/PredicatedSortedSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/PredicatedSortedSetTest.java @@ -24,7 +24,6 @@ import java.util.Set; import java.util.SortedSet; import java.util.TreeSet; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Predicate; import org.apache.commons.collections4.functors.TruePredicate; import org.junit.jupiter.api.Test; @@ -41,10 +40,6 @@ public class PredicatedSortedSetTest extends AbstractSortedSetTest { super(PredicatedSortedSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PredicatedSortedSetTest.class); - } - protected Predicate truePredicate = TruePredicate.truePredicate(); @Override diff --git a/src/test/java/org/apache/commons/collections4/set/TransformedNavigableSetTest.java b/src/test/java/org/apache/commons/collections4/set/TransformedNavigableSetTest.java index 1ef91f6bf..0c77cfed3 100644 --- a/src/test/java/org/apache/commons/collections4/set/TransformedNavigableSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/TransformedNavigableSetTest.java @@ -22,7 +22,6 @@ import java.util.NavigableSet; import java.util.Set; import java.util.TreeSet; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Transformer; import org.apache.commons.collections4.collection.TransformedCollectionTest; import org.junit.jupiter.api.Test; @@ -39,10 +38,6 @@ public class TransformedNavigableSetTest extends AbstractNavigableSetTest super(TransformedNavigableSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TransformedNavigableSetTest.class); - } - @Override @SuppressWarnings("unchecked") public NavigableSet makeObject() { diff --git a/src/test/java/org/apache/commons/collections4/set/TransformedSortedSetTest.java b/src/test/java/org/apache/commons/collections4/set/TransformedSortedSetTest.java index 4530ba097..a3be39635 100644 --- a/src/test/java/org/apache/commons/collections4/set/TransformedSortedSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/TransformedSortedSetTest.java @@ -22,7 +22,6 @@ import java.util.Set; import java.util.SortedSet; import java.util.TreeSet; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Transformer; import org.apache.commons.collections4.collection.TransformedCollectionTest; import org.junit.jupiter.api.Test; @@ -39,10 +38,6 @@ public class TransformedSortedSetTest extends AbstractSortedSetTest { super(TransformedSortedSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(TransformedSortedSetTest.class); - } - @Override @SuppressWarnings("unchecked") public SortedSet makeObject() { diff --git a/src/test/java/org/apache/commons/collections4/set/UnmodifiableNavigableSetTest.java b/src/test/java/org/apache/commons/collections4/set/UnmodifiableNavigableSetTest.java index 530d6d1f2..ce7789b59 100644 --- a/src/test/java/org/apache/commons/collections4/set/UnmodifiableNavigableSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/UnmodifiableNavigableSetTest.java @@ -25,7 +25,6 @@ import java.util.NavigableSet; import java.util.Set; import java.util.TreeSet; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -42,10 +41,6 @@ public class UnmodifiableNavigableSetTest extends AbstractNavigableSetTest super(UnmodifiableNavigableSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableNavigableSetTest.class); - } - @Override public NavigableSet makeObject() { return UnmodifiableNavigableSet.unmodifiableNavigableSet(new TreeSet<>()); diff --git a/src/test/java/org/apache/commons/collections4/set/UnmodifiableSetTest.java b/src/test/java/org/apache/commons/collections4/set/UnmodifiableSetTest.java index e37f993f5..f448923b5 100644 --- a/src/test/java/org/apache/commons/collections4/set/UnmodifiableSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/UnmodifiableSetTest.java @@ -22,7 +22,6 @@ import java.util.Arrays; import java.util.HashSet; import java.util.Set; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Unmodifiable; import org.junit.jupiter.api.Test; @@ -38,10 +37,6 @@ public class UnmodifiableSetTest extends AbstractSetTest { super(UnmodifiableSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableSetTest.class); - } - @Override public Set makeObject() { return UnmodifiableSet.unmodifiableSet(new HashSet()); diff --git a/src/test/java/org/apache/commons/collections4/set/UnmodifiableSortedSetTest.java b/src/test/java/org/apache/commons/collections4/set/UnmodifiableSortedSetTest.java index d7d866977..26210259b 100644 --- a/src/test/java/org/apache/commons/collections4/set/UnmodifiableSortedSetTest.java +++ b/src/test/java/org/apache/commons/collections4/set/UnmodifiableSortedSetTest.java @@ -26,7 +26,6 @@ import java.util.Set; import java.util.SortedSet; import java.util.TreeSet; -import org.apache.commons.collections4.BulkTest; import org.junit.jupiter.api.Test; /** @@ -43,10 +42,6 @@ public class UnmodifiableSortedSetTest extends AbstractSortedSetTest { super(UnmodifiableSortedSetTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableSortedSetTest.class); - } - @Override public SortedSet makeObject() { return UnmodifiableSortedSet.unmodifiableSortedSet(new TreeSet()); diff --git a/src/test/java/org/apache/commons/collections4/trie/PatriciaTrie2Test.java b/src/test/java/org/apache/commons/collections4/trie/PatriciaTrie2Test.java index 956ba5f8e..f4802c5bd 100644 --- a/src/test/java/org/apache/commons/collections4/trie/PatriciaTrie2Test.java +++ b/src/test/java/org/apache/commons/collections4/trie/PatriciaTrie2Test.java @@ -16,7 +16,6 @@ */ package org.apache.commons.collections4.trie; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.OrderedMap; import org.apache.commons.collections4.map.AbstractOrderedMapTest; @@ -31,10 +30,6 @@ public class PatriciaTrie2Test extends AbstractOrderedMapTest { super(PatriciaTrie2Test.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PatriciaTrie2Test.class); - } - @Override public OrderedMap makeObject() { return new PatriciaTrie<>(); diff --git a/src/test/java/org/apache/commons/collections4/trie/PatriciaTrieTest.java b/src/test/java/org/apache/commons/collections4/trie/PatriciaTrieTest.java index b176b4849..de20aea0b 100755 --- a/src/test/java/org/apache/commons/collections4/trie/PatriciaTrieTest.java +++ b/src/test/java/org/apache/commons/collections4/trie/PatriciaTrieTest.java @@ -26,7 +26,6 @@ import java.util.NoSuchElementException; import java.util.Set; import java.util.SortedMap; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Trie; import org.apache.commons.collections4.map.AbstractSortedMapTest; import org.junit.jupiter.api.Assertions; @@ -43,10 +42,6 @@ public class PatriciaTrieTest extends AbstractSortedMapTest { super(PatriciaTrieTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(PatriciaTrieTest.class); - } - @Override public SortedMap makeObject() { return new PatriciaTrie<>(); diff --git a/src/test/java/org/apache/commons/collections4/trie/UnmodifiableTrieTest.java b/src/test/java/org/apache/commons/collections4/trie/UnmodifiableTrieTest.java index 6f3019b1e..7c6fe4f11 100644 --- a/src/test/java/org/apache/commons/collections4/trie/UnmodifiableTrieTest.java +++ b/src/test/java/org/apache/commons/collections4/trie/UnmodifiableTrieTest.java @@ -18,7 +18,6 @@ package org.apache.commons.collections4.trie; import static org.junit.jupiter.api.Assertions.assertThrows; -import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.Trie; import org.apache.commons.collections4.Unmodifiable; import org.apache.commons.collections4.map.AbstractSortedMapTest; @@ -36,10 +35,6 @@ public class UnmodifiableTrieTest extends AbstractSortedMapTest { super(UnmodifiableTrieTest.class.getSimpleName()); } - public static junit.framework.Test suite() { - return BulkTest.makeSuite(UnmodifiableTrieTest.class); - } - @Override public Trie makeObject() { return UnmodifiableTrie.unmodifiableTrie(new PatriciaTrie());