Methods Summary |
---|
private static java.util.ArrayList | newArrayList(E elements)
ArrayList<E> list = new ArrayList<E>();
Collections.addAll(list, elements);
return list;
|
public void | testAndPredicate_AllConditionsTrue()
assertTrue(Predicates.and(newArrayList(TRUE)).apply(null));
assertTrue(Predicates.and(newArrayList(TRUE, TRUE)).apply(null));
|
public void | testAndPredicate_AtLeastOneConditionIsFalse()
assertFalse(Predicates.and(newArrayList(FALSE, TRUE, TRUE)).apply(null));
assertFalse(Predicates.and(newArrayList(TRUE, FALSE, TRUE)).apply(null));
assertFalse(Predicates.and(newArrayList(TRUE, TRUE, FALSE)).apply(null));
|
public void | testNotPredicate()
assertTrue(Predicates.not(FALSE).apply(null));
assertFalse(Predicates.not(TRUE).apply(null));
|
public void | testOrPredicate_AllConditionsFalse()
assertFalse(Predicates.or(newArrayList(FALSE, FALSE, FALSE)).apply(null));
|
public void | testOrPredicate_AllConditionsTrue()
assertTrue(Predicates.or(newArrayList(TRUE, TRUE, TRUE)).apply(null));
|
public void | testOrPredicate_AtLeastOneConditionIsTrue()
assertTrue(Predicates.or(newArrayList(TRUE, FALSE, FALSE)).apply(null));
assertTrue(Predicates.or(newArrayList(FALSE, TRUE, FALSE)).apply(null));
assertTrue(Predicates.or(newArrayList(FALSE, FALSE, TRUE)).apply(null));
|