@Test
public void testHasBoth() {

    when(params.getPredefinedSetOfPages()).thenReturn(PredefinedSetOfPages.EVEN_PAGES);
    when(params.getPageSelection()).thenReturn(Collections.singleton(range));
    assertTrue(victim.isValid(params, null));
}