예제 #1
0
  @Test
  public void shouldNeqToEverythingIfIsNull() {
    Place place = new Place();
    place.setWasFoundAt("aaa");
    boolean res = Predicates.wasFoundAt(null).appliesTo(place);
    Assert.assertFalse(res);

    place.setWasFoundAt(null);
    res = Predicates.wasFoundAt(null).appliesTo(place);
    Assert.assertFalse(res);
  }
예제 #2
0
 @Test
 public void shouldNeqPageItWasFetchedFromIfItIsDifferent() {
   Place place = new Place();
   place.setWasFoundAt("aaa");
   boolean res = Predicates.wasFoundAt("aab").appliesTo(place);
   Assert.assertFalse(res);
 }
예제 #3
0
 @Test
 public void shouldEqPageItWasFetchedFrom() {
   Place place = new Place();
   place.setWasFoundAt("aaa");
   boolean res = Predicates.wasFoundAt("aaa").appliesTo(place);
   Assert.assertTrue(res);
 }