#BAEL-18411 change code sample to use equals instead of equalsIgnoreCase and add commented out break statement mentioned in the article.
@@ -33,9 +33,9 @@ public class CollectionFilteringUnitTest {
for (Employee employee : originalList) {
for (String name : nameFilter) {
- if (employee.getName()
- .equalsIgnoreCase(name)) {
+ if (employee.getName().equals(name)) {
filteredList.add(employee);
+ //break;
}
}
}
