Affects PMD Version:
6.52.0+
7.0.0
JDK version: 17
Rule:
JUnitTestsShouldIncludeAssert
https://pmd.sourceforge.io/pmd-6.52.0/pmd_rules_java_bestpractices.html#junittestsshouldincludeassert
Description:
Code Sample demonstrating the issue:
CompletionStage<Object> future = ...;
future.whenComplete(
(data, exception) -> {
assertNotNull(data, "Data shouldn't be null");
});
Expected outcome:
PMD recognizes "assertNotNull".
Affects PMD Version:
6.52.0+
7.0.0
JDK version: 17
Rule:
JUnitTestsShouldIncludeAssert
https://pmd.sourceforge.io/pmd-6.52.0/pmd_rules_java_bestpractices.html#junittestsshouldincludeassert
Description:
Code Sample demonstrating the issue:
Expected outcome:
PMD recognizes "assertNotNull".