CircularLinkedList extends AbstractSequentialList<E> implements List<E>, Deque<E>, Cloneable, java.io.Serializable { public ListIterator<E> listIterator(int index) { checkPositionIndex(index); return new ListItr(index); } CircularLinkedList();  CircularLinkedList(Collection<? extends E> c); E getFirst(); E getLast(); E removeFirst(); E removeLast(); void addFirst(E e); void addLast(E e); boolean contains(Object o); int size(); boolean add(E e); void add(int index, E element); boolean remove(Object o); E remove(int index); E remove(); boolean addAll(Collection<? extends E> c); boolean addAll(int index, Collection<? extends E> c); void clear(); E get(int index); E set(int index, E element); int indexOf(Object o); int lastIndexOf(Object o); E peek(); E element(); E poll(); boolean offer(E e); boolean offerFirst(E e); boolean offerLast(E e); E peekFirst(); E peekLast(); E pollFirst(); E pollLast(); void push(E e); E pop(); boolean removeFirstOccurrence(Object o); boolean removeLastOccurrence(Object o); ListIterator<E> listIterator(int index); Iterator<E> descendingIterator(); Object clone(); Object[] toArray(); @SuppressWarnings("unchecked") T[] toArray(T[] a); @Override Spliterator<E> spliterator();  }
@Test public void listIterator_NoneAndEmptyList_ShouldNotHaveNext() { List<Integer> list = new CircularLinkedList<Integer>(); ListIterator<Integer> it = list.listIterator(); assertFalse(it.hasNext()); }
@Test(expected = NoSuchElementException.class) public void next_EmptyListIterator_ShouldThrowNoSuchElementException() { List<Integer> list = new CircularLinkedList<Integer>(); ListIterator<Integer> it = list.listIterator(); it.next(); }
@Test(expected = NoSuchElementException.class) public void previous_EmptyListIterator_ShouldThrowNoSuchElementException() { List<Integer> list = new CircularLinkedList<Integer>(); ListIterator<Integer> it = list.listIterator(); it.previous(); }