at.willhaben.willtest.proxy.assertions.AbstractRequestAssertion Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of core Show documentation
Show all versions of core Show documentation
Core classes with as few dependencies as possible
package at.willhaben.willtest.proxy.assertions;
import org.hamcrest.TypeSafeMatcher;
import java.util.Collection;
import java.util.List;
import java.util.function.Predicate;
import java.util.stream.Collectors;
public abstract class AbstractRequestAssertion extends TypeSafeMatcher {
public boolean oneOrMoreMatch(Collection list, Predicate filterMethod) {
List filteredEntries = list.stream()
.filter(filterMethod)
.collect(Collectors.toList());
return filteredEntries.size() > 0;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy