@Test public void isInScope() { Assert.assertTrue(filter.isInScope(changeScope, Collections.singleton(new File("./target/test-classes")))); }
@Override public boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs) { List<String> filePaths = mainSourceDirs.stream() .map(dir -> changeScope.getAllAffectedClasses().stream() .map(className -> className.replace(JAVA.extension(), CLASS.extension())) .map(name -> dir + File.separator + name) .collect(toList())) .flatMap(List::stream) .collect(toList()); return filePaths.stream() .map(File::new) .anyMatch(File::exists); }
ChangeScopeFilter implements ScopeFilter<ChangeScope<Change>, Set<File>> { @Override public boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs) { List<String> filePaths = mainSourceDirs.stream() .map(dir -> changeScope.getAllAffectedClasses().stream() .map(className -> className.replace(JAVA.extension(), CLASS.extension())) .map(name -> dir + File.separator + name) .collect(toList())) .flatMap(List::stream) .collect(toList()); return filePaths.stream() .map(File::new) .anyMatch(File::exists); } }
ChangeScopeFilter implements ScopeFilter<ChangeScope<Change>, Set<File>> { @Override public boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs) { List<String> filePaths = mainSourceDirs.stream() .map(dir -> changeScope.getAllAffectedClasses().stream() .map(className -> className.replace(JAVA.extension(), CLASS.extension())) .map(name -> dir + File.separator + name) .collect(toList())) .flatMap(List::stream) .collect(toList()); return filePaths.stream() .map(File::new) .anyMatch(File::exists); }  }
ChangeScopeFilter implements ScopeFilter<ChangeScope<Change>, Set<File>> { @Override public boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs) { List<String> filePaths = mainSourceDirs.stream() .map(dir -> changeScope.getAllAffectedClasses().stream() .map(className -> className.replace(JAVA.extension(), CLASS.extension())) .map(name -> dir + File.separator + name) .collect(toList())) .flatMap(List::stream) .collect(toList()); return filePaths.stream() .map(File::new) .anyMatch(File::exists); }  @Override boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs); }
ChangeScopeFilter implements ScopeFilter<ChangeScope<Change>, Set<File>> { @Override public boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs) { List<String> filePaths = mainSourceDirs.stream() .map(dir -> changeScope.getAllAffectedClasses().stream() .map(className -> className.replace(JAVA.extension(), CLASS.extension())) .map(name -> dir + File.separator + name) .collect(toList())) .flatMap(List::stream) .collect(toList()); return filePaths.stream() .map(File::new) .anyMatch(File::exists); }  @Override boolean isInScope(ChangeScope<Change> changeScope, Set<File> mainSourceDirs);  }