Merge pull request #219 from hapifhir/PackageCacheManager_fix

Package cache manager fix
This commit is contained in:
Mark Iantorno 2020-06-04 10:35:47 -04:00 committed by GitHub
commit 74c8ba0580
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 3 deletions

View File

@ -13,7 +13,7 @@ import org.hl7.fhir.r5.formats.IParser.OutputStyle;
import org.hl7.fhir.r5.model.StructureDefinition; import org.hl7.fhir.r5.model.StructureDefinition;
import org.hl7.fhir.r5.test.utils.TestingUtilities; import org.hl7.fhir.r5.test.utils.TestingUtilities;
import org.hl7.fhir.r5.utils.FHIRPathEngine; import org.hl7.fhir.r5.utils.FHIRPathEngine;
import org.hl7.fhir.utilities.cache.PackageCacheManager; import org.hl7.fhir.utilities.cache.FilesystemPackageCacheManager;
import org.hl7.fhir.utilities.cache.ToolsVersion; import org.hl7.fhir.utilities.cache.ToolsVersion;
import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
@ -25,7 +25,7 @@ public class XmlParserTests {
@BeforeAll @BeforeAll
public static void setUp() throws Exception { public static void setUp() throws Exception {
PackageCacheManager pcm = new PackageCacheManager(true, ToolsVersion.TOOLS_VERSION); FilesystemPackageCacheManager pcm = new FilesystemPackageCacheManager(true, ToolsVersion.TOOLS_VERSION);
context = SimpleWorkerContext.fromPackage(pcm.loadPackage("hl7.fhir.r4.core", "4.0.1")); context = SimpleWorkerContext.fromPackage(pcm.loadPackage("hl7.fhir.r4.core", "4.0.1"));
fp = new FHIRPathEngine(context); fp = new FHIRPathEngine(context);

View File

@ -147,7 +147,9 @@
<target>1.8</target> <target>1.8</target>
<forceJavacCompilerUse>false</forceJavacCompilerUse> <forceJavacCompilerUse>false</forceJavacCompilerUse>
<encoding>UTF-8</encoding> <encoding>UTF-8</encoding>
<fork>false</fork> <!-- Allows running the compiler in a separate process. If false it uses the built in compiler,
while if true it will use an executable. -->
<fork>true</fork>
<meminitial>512m</meminitial> <meminitial>512m</meminitial>
<maxmem>4000m</maxmem> <maxmem>4000m</maxmem>
<debug>true</debug> <debug>true</debug>
@ -159,6 +161,9 @@
<artifactId>maven-surefire-plugin</artifactId> <artifactId>maven-surefire-plugin</artifactId>
<version>${maven_surefire_version}</version> <version>${maven_surefire_version}</version>
<configuration> <configuration>
<forkCount>1</forkCount>
<reuseForks>true</reuseForks>
<parallel>classes</parallel>
<trimStackTrace>false</trimStackTrace> <trimStackTrace>false</trimStackTrace>
<testFailureIgnore>false</testFailureIgnore> <testFailureIgnore>false</testFailureIgnore>
<!-- We need to include the ${argLine} here so the Jacoco test arguments are included in the <!-- We need to include the ${argLine} here so the Jacoco test arguments are included in the