@Test void testEmpty() { when(bundleContext.getBundles()).thenReturn(new Bundle[0]); assertTrue(underTest.getBundles().isEmpty()); }
@Override @SuppressWarnings("null") public @NotNull Collection<BundleInfo> getBundles() { return Arrays.stream(bundleContext.getBundles()) .map(bundle -> (BundleInfo)new BundleInfoImpl(bundle)) .collect(Collectors.toCollection(() -> new TreeSet<BundleInfo>())); }
BundleInfoServiceImpl implements BundleInfoService { @Override @SuppressWarnings("null") public @NotNull Collection<BundleInfo> getBundles() { return Arrays.stream(bundleContext.getBundles()) .map(bundle -> (BundleInfo)new BundleInfoImpl(bundle)) .collect(Collectors.toCollection(() -> new TreeSet<BundleInfo>())); } }
BundleInfoServiceImpl implements BundleInfoService { @Override @SuppressWarnings("null") public @NotNull Collection<BundleInfo> getBundles() { return Arrays.stream(bundleContext.getBundles()) .map(bundle -> (BundleInfo)new BundleInfoImpl(bundle)) .collect(Collectors.toCollection(() -> new TreeSet<BundleInfo>())); }  }
BundleInfoServiceImpl implements BundleInfoService { @Override @SuppressWarnings("null") public @NotNull Collection<BundleInfo> getBundles() { return Arrays.stream(bundleContext.getBundles()) .map(bundle -> (BundleInfo)new BundleInfoImpl(bundle)) .collect(Collectors.toCollection(() -> new TreeSet<BundleInfo>())); }  @Override @SuppressWarnings("null") @NotNull Collection<BundleInfo> getBundles(); }
BundleInfoServiceImpl implements BundleInfoService { @Override @SuppressWarnings("null") public @NotNull Collection<BundleInfo> getBundles() { return Arrays.stream(bundleContext.getBundles()) .map(bundle -> (BundleInfo)new BundleInfoImpl(bundle)) .collect(Collectors.toCollection(() -> new TreeSet<BundleInfo>())); }  @Override @SuppressWarnings("null") @NotNull Collection<BundleInfo> getBundles();  }