nhojpatrick commented on a change in pull request #282: URL: https://github.com/apache/commons-collections/pull/282#discussion_r818412923
########## File path: src/test/java/org/apache/commons/collections4/collection/PredicatedCollectionTest.java ########## @@ -99,12 +98,9 @@ public void testIllegalAddAll() { elements.add((E) "two"); elements.add((E) Integer.valueOf(3)); elements.add((E) "four"); - try { - c.addAll(elements); - fail("Integer should fail string predicate."); - } catch (final IllegalArgumentException e) { - // expected - } + + assertThrows(IllegalArgumentException.class, () -> c.addAll(elements)); Review comment: ditto too -- 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: issues-unsubscr...@commons.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org