mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
copy coverage agent jars to temp directory ignoring others jars from community/lib
This commit is contained in:
@@ -25,6 +25,7 @@ import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileFilter;
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
@@ -77,7 +78,15 @@ public abstract class JavaCoverageRunner extends CoverageRunner {
|
||||
|
||||
try {
|
||||
LOG.info("Coverage jars were copied to " + dir.getPath());
|
||||
FileUtil.copyDir(new File(agentPath), dir);
|
||||
FileUtil.copyDir(new File(agentPath), dir, new FileFilter() {
|
||||
@Override
|
||||
public boolean accept(File file) {
|
||||
final String fileName = file.getName();
|
||||
return fileName.startsWith("coverage-") ||
|
||||
fileName.startsWith("asm-all") ||
|
||||
fileName.startsWith("trove4j");
|
||||
}
|
||||
});
|
||||
return dir.getPath();
|
||||
}
|
||||
catch (IOException e) {
|
||||
|
||||
Reference in New Issue
Block a user