Bump core version (#3067)
* Bump core version * Changes for version bump * Resolve NPE: * Test fix Co-authored-by: jamesagnew <jamesagnew@gmail.com>
This commit is contained in:
parent
a0388db672
commit
120443e561
|
@ -75,12 +75,12 @@ public class IgInstallerDstu3Test extends BaseJpaDstu3Test {
|
|||
|
||||
byte[] bytes = loadResourceAsByteArray("/packages/erroneous-ig.tar.gz");
|
||||
|
||||
// Unknown base of StructureDefinitions
|
||||
// That patient profile in this NPM package has an invalid base
|
||||
try {
|
||||
igInstaller.install(new PackageInstallationSpec().setName("erroneous-ig").setVersion("1.0.2").setInstallMode(PackageInstallationSpec.InstallModeEnum.STORE_AND_INSTALL).setPackageContents(bytes));
|
||||
fail();
|
||||
} catch (ImplementationGuideInstallationException e) {
|
||||
assertThat(e.getMessage(), containsString("Failure when generating snapshot of StructureDefinition"));
|
||||
assertThat(e.getMessage(), containsString("Could not load NPM package erroneous-ig#1.0.2"));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Binary file not shown.
|
@ -88,7 +88,7 @@ public class SearchParamExtractorR5 extends BaseSearchParamExtractor implements
|
|||
private final Map<String, Base> myResourceTypeToStub = Collections.synchronizedMap(new HashMap<>());
|
||||
|
||||
@Override
|
||||
public Base resolveConstant(Object appContext, String name, boolean beforeContext) throws PathEngineException {
|
||||
public List<Base> resolveConstant(Object appContext, String name, boolean beforeContext) throws PathEngineException {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
|
|
@ -189,7 +189,7 @@ public final class HapiWorkerContext extends I18nBase implements IWorkerContext
|
|||
severity = IssueSeverity.fromCode(result.getSeverityCode());
|
||||
}
|
||||
ConceptDefinitionComponent definition = new ConceptDefinitionComponent().setCode(result.getCode());
|
||||
return new ValidationResult(severity, result.getMessage(), definition);
|
||||
return new ValidationResult(severity, result.getMessage(), theSystem, definition);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -206,7 +206,7 @@ public final class HapiWorkerContext extends I18nBase implements IWorkerContext
|
|||
ConceptDefinitionComponent definition = new ConceptDefinitionComponent();
|
||||
definition.setCode(theCode);
|
||||
definition.setDisplay(outcome.getDisplay());
|
||||
return new ValidationResult(definition);
|
||||
return new ValidationResult(theSystem, definition);
|
||||
}
|
||||
|
||||
return new ValidationResult(IssueSeverity.ERROR, "Unknown code[" + theCode + "] in system[" + Constants.codeSystemWithDefaultDescription(theSystem) + "]");
|
||||
|
|
|
@ -274,9 +274,10 @@ public class FhirInstanceValidator extends BaseValidatorBridge implements IInsta
|
|||
|
||||
|
||||
public static class NullEvaluationContext implements FHIRPathEngine.IEvaluationContext {
|
||||
|
||||
@Override
|
||||
public Base resolveConstant(Object appContext, String name, boolean beforeContext) throws PathEngineException {
|
||||
return null;
|
||||
public List<Base> resolveConstant(Object appContext, String name, boolean beforeContext) throws PathEngineException {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -247,7 +247,7 @@ public class VersionSpecificWorkerContextWrapper extends I18nBase implements IWo
|
|||
}
|
||||
|
||||
@Nonnull
|
||||
private ValidationResult convertValidationResult(@Nullable IValidationSupport.CodeValidationResult theResult) {
|
||||
private ValidationResult convertValidationResult(String theSystem, @Nullable IValidationSupport.CodeValidationResult theResult) {
|
||||
ValidationResult retVal = null;
|
||||
if (theResult != null) {
|
||||
String code = theResult.getCode();
|
||||
|
@ -255,7 +255,7 @@ public class VersionSpecificWorkerContextWrapper extends I18nBase implements IWo
|
|||
String issueSeverity = theResult.getSeverityCode();
|
||||
String message = theResult.getMessage();
|
||||
if (isNotBlank(code)) {
|
||||
retVal = new ValidationResult(new org.hl7.fhir.r5.model.CodeSystem.ConceptDefinitionComponent()
|
||||
retVal = new ValidationResult(theSystem, new org.hl7.fhir.r5.model.CodeSystem.ConceptDefinitionComponent()
|
||||
.setCode(code)
|
||||
.setDisplay(display));
|
||||
} else if (isNotBlank(issueSeverity)) {
|
||||
|
@ -589,7 +589,7 @@ public class VersionSpecificWorkerContextWrapper extends I18nBase implements IWo
|
|||
} else {
|
||||
result = myValidationSupportContext.getRootValidationSupport().validateCode(myValidationSupportContext, theValidationOptions, theSystem, theCode, theDisplay, null);
|
||||
}
|
||||
return convertValidationResult(result);
|
||||
return convertValidationResult(theSystem, result);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in New Issue