### Question:
ClassPathUtils { public static Set<String> scanClassPathWithExcludes(final String classPath, final Set<String> excludeJarSet, final Set<String> excludePrefixes) { final Set<String> pathSet = new HashSet<String>(); __JDKPaths.processClassPathItem(classPath, excludeJarSet, pathSet); return filterPathSet(pathSet, excludePrefixes, Collections.<String>emptySet()); }  static Set<String> getJdkPaths(); @Nullable static Path findRootPathForResource(String resourceName, ClassLoader classLoader); @Nullable static Path findRootPathForClass(Class<?> clazz); static Path getJarPathFromUrl(URL jarUrl); static Set<Path> getDirectoriesFromJar(Path pathToJarFile); static String classToResourceName(Class<?> clazz); static String classNameToResourceName(String className); static Set<String> scanClassPath(final String classPath, final Set<String> excludeJarSet); static Set<String> scanClassPath(final String classPath, final Set<String> excludeJarSet, final Set<String> excludePrefixes, final Set<String> includePrefixes); static Set<String> scanClassPathWithExcludes(final String classPath, final Set<String> excludeJarSet, final Set<String> excludePrefixes); static Set<String> scanClassPathWithIncludes(final String classPath, final Set<String> excludeJarSet, final Set<String> includePrefixes);  }### Answer:
@Test public void testScanClassPathWithExcludes() throws Exception { Set<String> excludePrefixes = new HashSet<String>(); Collections.addAll(excludePrefixes, "com/netflix/foo/bar"); Set<String> pkgPaths = ClassPathUtils.scanClassPathWithExcludes(classPathStr, Collections.<String>emptySet(), excludePrefixes); Set<String> notExpected = new HashSet<String>(); Collections.addAll(notExpected, "com/netflix/foo/bar"); Set<String> expected = new HashSet<String>(); Collections.addAll(expected, "com/netflix/nicobar/hello", "com/netflix/nicobar/test/ui", "com/netflix/foo", "com/netflix/baz/internal", "com/netflix/nicobar/test/ui/internal", "com/netflix/nicobar/test", "com/netflix/nicobar/hello/internal"); assertTrue(pkgPaths.containsAll(expected)); for (String excluded: notExpected) { assertTrue(!pkgPaths.contains(excluded)); } }