This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-collections.git
The following commit(s) were added to refs/heads/master by this push: new b29813945 [COLLECTIONS-777] Migrate to JUnit 5 b29813945 is described below commit b29813945d714ee8bc2208d802bad0e9a701f83b Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Mon Nov 11 09:07:54 2024 -0500 [COLLECTIONS-777] Migrate to JUnit 5 Remove unused methods --- .../org/apache/commons/collections4/BulkTest.java | 129 +-------------------- 1 file changed, 1 insertion(+), 128 deletions(-) diff --git a/src/test/java/org/apache/commons/collections4/BulkTest.java b/src/test/java/org/apache/commons/collections4/BulkTest.java index 2041eba5a..105b47183 100644 --- a/src/test/java/org/apache/commons/collections4/BulkTest.java +++ b/src/test/java/org/apache/commons/collections4/BulkTest.java @@ -17,113 +17,7 @@ package org.apache.commons.collections4; /** - * A {@code TestCase} that can define both simple and bulk test methods. - * <p> - * A <em>simple test method</em> is the type of test traditionally - * supplied by {@code TestCase}. To define a simple test, create a public - * no-argument method whose name starts with "test". You can specify - * the name of simple test in the constructor of {@code BulkTest}; - * a subsequent call to {@code TestCase#run} will run that simple test. - * <p> - * A <em>bulk test method</em>, on the other hand, returns a new instance - * of {@code BulkTest}, which can itself define new simple and bulk - * test methods. By using the {@code #makeSuite} method, you can - * automatically create a hierarchical suite of tests and child bulk tests. - * <p> - * For instance, consider the following two classes: - * - * <Pre> - * public class SetTest extends BulkTest { - * - * private Set set; - * - * public SetTest(Set set) { - * this.set = set; - * } - * - * @Test - * public void testContains() { - * boolean r = set.contains(set.iterator().next())); - * assertTrue("Set should contain first element, r); - * } - * - * @Test - * public void testClear() { - * set.clear(); - * assertTrue("Set should be empty after clear", set.isEmpty()); - * } - * } - * - * - * public class HashMapTest extends BulkTest { - * - * private Map makeFullMap() { - * HashMap result = new HashMap(); - * result.put("1", "One"); - * result.put("2", "Two"); - * return result; - * } - * - * @Test - * public void testClear() { - * Map map = makeFullMap(); - * map.clear(); - * assertTrue("Map empty after clear", map.isEmpty()); - * } - * - * public BulkTest bulkTestKeySet() { - * return new SetTest(makeFullMap().keySet()); - * } - * - * public BulkTest bulkTestEntrySet() { - * return new SetTest(makeFullMap().entrySet()); - * } - * } - * </Pre> - * - * In the above examples, {@code SetTest} defines two - * simple test methods and no bulk test methods; {@code HashMapTest} - * defines one simple test method and two bulk test methods. When - * {@code makeSuite(HashMapTest.class).run} is executed, - * <em>five</em> simple test methods will be run, in this order:<P> - * - * <Ol> - * <Li>HashMapTest.testClear() - * <Li>HashMapTest.bulkTestKeySet().testContains(); - * <Li>HashMapTest.bulkTestKeySet().testClear(); - * <Li>HashMapTest.bulkTestEntrySet().testContains(); - * <Li>HashMapTest.bulkTestEntrySet().testClear(); - * </Ol> - * - * In the graphical junit test runners, the tests would be displayed in - * the following tree:<P> - * - * <UL> - * <LI>HashMapTest</LI> - * <UL> - * <LI>testClear - * <LI>bulkTestKeySet - * <UL> - * <LI>testContains - * <LI>testClear - * </UL> - * <LI>bulkTestEntrySet - * <UL> - * <LI>testContains - * <LI>testClear - * </UL> - * </UL> - * </UL> - * - * A subclass can override a superclass's bulk test by - * returning {@code null} from the bulk test method. If you only - * want to override specific simple tests within a bulk test, use the - * {@code #ignoredTests} method.<P> - * - * Note that if you want to use the bulk test methods, you <em>must</em> - * define your {@code suite()} method to use {@code #makeSuite}. - * The ordinary {@code TestSuite} constructor doesn't know how to - * interpret bulk test methods. + * This class is left over from the JUnit 3 implementation. */ public class BulkTest implements Cloneable { @@ -182,13 +76,6 @@ public class BulkTest implements Cloneable { return name; } - /** - * For Apache Commons BeanUtils until all components migrate to JUnit 5. - */ - public String getVerboseName() { - return verboseName; - } - /** * Returns an array of test names to ignore.<P> * @@ -226,20 +113,6 @@ public class BulkTest implements Cloneable { return null; } - /** - * For Apache Commons BeanUtils until all components migrate to JUnit 5. - */ - public void setName(final String name) { - this.name = name; - } - - /** - * For Apache Commons BeanUtils until all components migrate to JUnit 5. - */ - public void setVerboseName(final String verboseName) { - this.verboseName = verboseName; - } - /** * Returns the display name of this {@code BulkTest}. *