### Question:
LimitedFifoObservableList extends ModifiableObservableListBase<T> { @Override public int size() { return list.size(); } LimitedFifoObservableList(int maxSize); int getMaxSize(); @Override T get(int index); @Override int size(); @Override boolean add(T element); @Override boolean addAll(Collection<? extends T> elements); @Override void clear(); @Override void add(int index, T element); @Override boolean addAll(int index, Collection<? extends T> elements); @Override boolean remove(Object element); @Override T remove(int index); @Override void remove(int from, int to); @Override boolean removeAll(Collection<?> elements); @Override boolean removeAll(@SuppressWarnings("unchecked") T... elements); @Override boolean removeIf(Predicate<? super T> filter); @Override void replaceAll(UnaryOperator<T> operator); @Override boolean retainAll(Collection<?> elements); @Override boolean retainAll(@SuppressWarnings("unchecked") T... elements); @Override T set(int index, T element); @Override boolean setAll(Collection<? extends T> col); @Override boolean setAll(@SuppressWarnings("unchecked") T... elements); @Override void sort(Comparator<? super T> comparator);  }### Answer:
@Test public void testSize() { final List<Object> list = getListWithMaxSize(1); assertThat(list.size(), is(0)); list.add(new Object()); assertThat(list.size(), is(1)); list.add(new Object()); assertThat(list.size(), is(1)); }