fix up structure mapping tests
This commit is contained in:
parent
3f5461346b
commit
f22316d55f
|
@ -1720,10 +1720,9 @@ public class StructureMapUtilities {
|
|||
Base dest = null;
|
||||
if (tgt.hasContext()) {
|
||||
dest = vars.get(VariableMode.OUTPUT, tgt.getContext());
|
||||
if (dest == null)
|
||||
throw new FHIRException("Rule \"" + rulePath + "\": target context not known: " + tgt.getContext());
|
||||
if (!tgt.hasElement())
|
||||
throw new FHIRException("Rule \"" + rulePath + "\": Not supported yet");
|
||||
if (dest == null) {
|
||||
throw new FHIRException("Rul \"" + rulePath + "\": target context not known: " + tgt.getContext());
|
||||
}
|
||||
}
|
||||
Base v = null;
|
||||
if (tgt.hasTransform()) {
|
||||
|
@ -1742,8 +1741,10 @@ public class StructureMapUtilities {
|
|||
v = dest.makeProperty(tgt.getElement().hashCode(), tgt.getElement());
|
||||
sharedVars.add(VariableMode.SHARED, tgt.getListRuleId(), v);
|
||||
}
|
||||
} else {
|
||||
} else if (tgt.hasElement()) {
|
||||
v = dest.makeProperty(tgt.getElement().hashCode(), tgt.getElement());
|
||||
} else {
|
||||
v = dest;
|
||||
}
|
||||
}
|
||||
if (tgt.hasVariable() && v != null)
|
||||
|
|
Loading…
Reference in New Issue