SortedUserList implements UserList { public List<UserListListener> getListeners() { return Collections.unmodifiableList(listeners); } SortedUserList(); @Override boolean add(final User user); @Nullable @Override User get(final int pos); @Override int indexOf(final User user); @Override boolean remove(final User user); @Override User set(final int pos, final User user); @Override int size(); @Override void addUserListListener(final UserListListener listener); @Override void removeUserListListener(final UserListListener listener); List<UserListListener> getListeners();  }
@Test public void getListenersShouldReturnNewListEveryTime() { assertNotSame(userList.getListeners(), userList.getListeners()); }