Claudenw commented on code in PR #335:
URL: 
https://github.com/apache/commons-collections/pull/335#discussion_r997172420


##########
src/test/java/org/apache/commons/collections4/bloomfilter/AbstractBitCountProducerTest.java:
##########
@@ -60,23 +48,37 @@ public boolean test(int index, int count) {
     @Override
     protected abstract BitCountProducer createEmptyProducer();
 
-    /**
-     * Determines if empty tests should be run.  Some producers do not 
implement an empty
-     * version.  Tests for those classes should return false.
-     * @return true if the empty tests are supported
-     */
-    protected boolean supportsEmpty() {
-        return true;
-    }
 
     @Test
-    public final void testForEachCount() {
-
+    public final void testForEachCountResults() {
         assertFalse(createProducer().forEachCount(FALSE_CONSUMER), "non-empty 
should be false");
         assertTrue(createProducer().forEachCount(TRUE_CONSUMER), "non-empty 
should be true");
-        if (supportsEmpty()) {
-            assertTrue(createEmptyProducer().forEachCount(FALSE_CONSUMER), 
"empty should be true");
-            assertTrue(createEmptyProducer().forEachCount(TRUE_CONSUMER), 
"empty should be true");
-        }
+        assertTrue(createEmptyProducer().forEachCount(FALSE_CONSUMER), "empty 
should be true");
+        assertTrue(createEmptyProducer().forEachCount(TRUE_CONSUMER), "empty 
should be true");
+    }
+
+    protected abstract int[][] getExpectedBitCount();

Review Comment:
   moved and code added.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to