@Override protected void init() { if (!initialized) { initialized = true; validateLibraries = project.getModules().isEmpty(); binaries = getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_BINARIES); List<File> libraries = getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_LIBRARIES); elements = Lists.newArrayList(binaries); elements.addAll(libraries); } }
@Override protected void init() { if (!initialized) { TimeProfiler profiler = new TimeProfiler(getClass()).start("JavaTestClasspath initialization"); initialized = true; validateLibraries = project.getModules().isEmpty(); binaries = getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_BINARIES); List<File> libraries = getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_LIBRARIES); if(libraries.isEmpty()) { LOG.warn("Bytecode of dependencies was not provided for analysis of test files, you might end up with less precise results. " + "Bytecode can be provided using sonar.java.test.libraries property"); } elements = Lists.newArrayList(binaries); elements.addAll(libraries); profiler.stop(); } }
@Override protected void init() { if (!initialized) { validateLibraries = fs.hasFiles(fs.predicates().all()); Profiler profiler = Profiler.create(LOG).startInfo("JavaTestClasspath initialization"); initialized = true; binaries = new ArrayList<>(getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_BINARIES)); Set<File> libraries = getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_LIBRARIES); if (libraries.isEmpty() && hasJavaSources()) { LOG.warn("Bytecode of dependencies was not provided for analysis of test files, you might end up with less precise results. " + "Bytecode can be provided using sonar.java.test.libraries property."); } elements = new ArrayList<>(binaries); elements.addAll(libraries); profiler.stopInfo(); } }
@Override protected void init() { if (!initialized) { validateLibraries = fs.hasFiles(fs.predicates().all()); Profiler profiler = Profiler.create(LOG).startInfo("JavaTestClasspath initialization"); initialized = true; binaries = new ArrayList<>(getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_BINARIES)); Set<File> libraries = getFilesFromProperty(JavaClasspathProperties.SONAR_JAVA_TEST_LIBRARIES); if (libraries.isEmpty() && hasJavaSources()) { LOG.warn("Bytecode of dependencies was not provided for analysis of test files, you might end up with less precise results. " + "Bytecode can be provided using sonar.java.test.libraries property."); } elements = new ArrayList<>(binaries); elements.addAll(libraries); profiler.stopInfo(); } }