@Test public void setFetchCountExceedsLowerBound() { int tooSmall = FETCH_COUNT_LOWER_BOUND - 1; Throwable actual = thrownBy( () -> timeline.setFetchCount( tooSmall ) ); assertNotNull( actual ); assertTrue( actual instanceof IllegalArgumentException ); assertTrue( actual.getMessage().contains( valueOf( tooSmall ) ) ); assertEquals( format( ERROR_EXCEEDS_LOWER_BOUND, tooSmall ), actual.getMessage() ); }
public void setFetchCount( int fetchCount ) { checkArgument( fetchCount >= FETCH_COUNT_LOWER_BOUND, ERROR_EXCEEDS_LOWER_BOUND, fetchCount ); checkArgument( fetchCount <= FETCH_COUNT_UPPER_BOUND, ERROR_EXCEEDS_UPPER_BOUND, fetchCount ); this.fetchCount = fetchCount; }
Timeline { public void setFetchCount( int fetchCount ) { checkArgument( fetchCount >= FETCH_COUNT_LOWER_BOUND, ERROR_EXCEEDS_LOWER_BOUND, fetchCount ); checkArgument( fetchCount <= FETCH_COUNT_UPPER_BOUND, ERROR_EXCEEDS_UPPER_BOUND, fetchCount ); this.fetchCount = fetchCount; } }
Timeline { public void setFetchCount( int fetchCount ) { checkArgument( fetchCount >= FETCH_COUNT_LOWER_BOUND, ERROR_EXCEEDS_LOWER_BOUND, fetchCount ); checkArgument( fetchCount <= FETCH_COUNT_UPPER_BOUND, ERROR_EXCEEDS_UPPER_BOUND, fetchCount ); this.fetchCount = fetchCount; } Timeline( ItemProvider itemProvider, SessionStorage sessionStorage  ); }
Timeline { public void setFetchCount( int fetchCount ) { checkArgument( fetchCount >= FETCH_COUNT_LOWER_BOUND, ERROR_EXCEEDS_LOWER_BOUND, fetchCount ); checkArgument( fetchCount <= FETCH_COUNT_UPPER_BOUND, ERROR_EXCEEDS_UPPER_BOUND, fetchCount ); this.fetchCount = fetchCount; } Timeline( ItemProvider itemProvider, SessionStorage sessionStorage  ); void setFetchCount( int fetchCount ); int getFetchCount(); List<Item> getItems(); void fetchItems(); }
Timeline { public void setFetchCount( int fetchCount ) { checkArgument( fetchCount >= FETCH_COUNT_LOWER_BOUND, ERROR_EXCEEDS_LOWER_BOUND, fetchCount ); checkArgument( fetchCount <= FETCH_COUNT_UPPER_BOUND, ERROR_EXCEEDS_UPPER_BOUND, fetchCount ); this.fetchCount = fetchCount; } Timeline( ItemProvider itemProvider, SessionStorage sessionStorage  ); void setFetchCount( int fetchCount ); int getFetchCount(); List<Item> getItems(); void fetchItems(); static final int FETCH_COUNT_LOWER_BOUND; static final int FETCH_COUNT_UPPER_BOUND; }