garydgregory commented on a change in pull request #209:
URL: 
https://github.com/apache/commons-collections/pull/209#discussion_r559061101



##########
File path: 
src/test/java/org/apache/commons/collections4/collection/PredicatedCollectionBuilderTest.java
##########
@@ -86,14 +89,14 @@ public void 
createPredicatedCollectionWithNotNullPredicate() {
     }
 
     private void checkPredicatedCollection1(final Collection<String> 
collection) {
-        Assert.assertEquals(1, collection.size());
+        assertEquals(1, collection.size());
 
         collection.add("test2");
-        Assert.assertEquals(2, collection.size());
+        assertEquals(2, collection.size());
 
         try {
             collection.add(null);
-            Assert.fail("Expecting IllegalArgumentException for failing 
predicate!");
+            fail("Expecting IllegalArgumentException for failing predicate!");

Review comment:
       Use assertThrows()

##########
File path: 
src/test/java/org/apache/commons/collections4/collection/PredicatedCollectionBuilderTest.java
##########
@@ -122,17 +125,17 @@ public void createPredicatedCollectionWithPredicate() {
     }
 
     private void checkPredicatedCollection2(final Collection<Integer> 
collection) {
-        Assert.assertEquals(2, collection.size());
+        assertEquals(2, collection.size());
 
         try {
             collection.add(4);
-            Assert.fail("Expecting IllegalArgumentException for failing 
predicate!");
+            fail("Expecting IllegalArgumentException for failing predicate!");

Review comment:
       Use assertThrows()




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to