PackageList implements Iterable<String> { public List<String> getPackages() { return Collections.unmodifiableList(packages); } PackageList();  PackageList(String... defaultPackages);  PackageList(List<String> defaultPackages, List<String> packages);  PackageList(List<String> packages); void add(String packageName); void addAll(String... packages); void addAll(Collection<String> packages); List<String> getDefaultPackages(); void setDefaultPackages(String... defaultPackages); List<String> getPackages(); @Override Iterator<String> iterator();  }
@Test public void shouldReturnEmptyListWhenNoPackagesAdded() { assertThat(packageList.getPackages()).isNotNull(); }