diff --git a/build.gradle b/build.gradle index 1ff5d40461..366629fa49 100644 --- a/build.gradle +++ b/build.gradle @@ -24,7 +24,7 @@ plugins { import org.owasp.dependencycheck.reporting.ReportGenerator apply from: 'project-properties.gradle' -apply from: "$scriptsUrl/build-docker.gradle" +//apply from: "$scriptsUrl/build-docker.gradle" apply from: "$scriptsUrl/build-commons.gradle" apply from: "$scriptsUrl/build-info.gradle" apply from: "$scriptsUrl/release-service.gradle" diff --git a/src/main/java/com/epam/ta/reportportal/core/analyzer/auto/indexer/BatchLogIndexer.java b/src/main/java/com/epam/ta/reportportal/core/analyzer/auto/indexer/BatchLogIndexer.java index 7a98614b1d..606b69f7d8 100644 --- a/src/main/java/com/epam/ta/reportportal/core/analyzer/auto/indexer/BatchLogIndexer.java +++ b/src/main/java/com/epam/ta/reportportal/core/analyzer/auto/indexer/BatchLogIndexer.java @@ -99,7 +99,7 @@ private Long indexPartition(List itemIds, AnalyzerConfig analyzerConfig, L private Long countLogs(List indexLaunch) { return indexLaunch.stream() .flatMap(launch -> launch.getTestItems().stream()) - .mapToLong(item -> item.getLogs().size()) + .mapToLong(item -> item.getLogs() != null ? item.getLogs().size() : 0) .sum(); } diff --git a/src/test/java/com/epam/ta/reportportal/core/imprt/XmlImportStrategyTest.java b/src/test/java/com/epam/ta/reportportal/core/imprt/XmlImportStrategyTest.java index 8dc2699d08..cc024c378a 100644 --- a/src/test/java/com/epam/ta/reportportal/core/imprt/XmlImportStrategyTest.java +++ b/src/test/java/com/epam/ta/reportportal/core/imprt/XmlImportStrategyTest.java @@ -26,6 +26,7 @@ import java.nio.file.Path; import java.time.Instant; import java.util.Date; +import java.util.HashSet; import java.util.Optional; import java.util.Set; import javax.inject.Provider; @@ -106,7 +107,12 @@ void whenImportLaunch_thenProcessXmlFile(@TempDir Path tempDir) throws Exception void whenImportLaunch_andIsSkippedIssue_thenProcessXmlFileWithSkippedTrue(@TempDir Path tempDir) throws Exception { LaunchImportRQ rq = new LaunchImportRQ(); - rq.setAttributes(Set.of(new ItemAttributesRQ(AbstractImportStrategy.SKIPPED_IS_NOT_ISSUE, "true"))); + ItemAttributesRQ attributesRQ = + new ItemAttributesRQ(AbstractImportStrategy.SKIPPED_IS_NOT_ISSUE, "true"); + attributesRQ.setSystem(true); + Set attributes = new HashSet<>(); + attributes.add(attributesRQ); + rq.setAttributes(attributes); File xmlFile = createFile(tempDir);