Fix test for correct type name in logical models (CDA)
This commit is contained in:
parent
29c2f46726
commit
9b94e6a1ec
|
@ -1086,6 +1086,7 @@ public class ProfileUtilities extends TranslatingUtilities {
|
|||
*/
|
||||
private void checkDifferential(List<ElementDefinition> elements, String type, String url) {
|
||||
boolean first = true;
|
||||
String t = urlTail(type);
|
||||
for (ElementDefinition ed : elements) {
|
||||
if (!ed.hasPath()) {
|
||||
throw new FHIRException(context.formatMessage(I18nConstants.NO_PATH_ON_ELEMENT_IN_DIFFERENTIAL_IN_, url));
|
||||
|
@ -1094,8 +1095,8 @@ public class ProfileUtilities extends TranslatingUtilities {
|
|||
if (p == null) {
|
||||
throw new FHIRException(context.formatMessage(I18nConstants.NO_PATH_VALUE_ON_ELEMENT_IN_DIFFERENTIAL_IN_, url));
|
||||
}
|
||||
if (!((first && type.equals(p)) || p.startsWith(type+"."))) {
|
||||
throw new FHIRException(context.formatMessage(I18nConstants.ILLEGAL_PATH__IN_DIFFERENTIAL_IN__MUST_START_WITH_, p, url, type, (first ? " (or be '"+type+"')" : "")));
|
||||
if (!((first && t.equals(p)) || p.startsWith(t+"."))) {
|
||||
throw new FHIRException(context.formatMessage(I18nConstants.ILLEGAL_PATH__IN_DIFFERENTIAL_IN__MUST_START_WITH_, p, url, t, (first ? " (or be '"+t+"')" : "")));
|
||||
}
|
||||
if (p.contains(".")) {
|
||||
// Element names (the parts of a path delineated by the '.' character) SHALL NOT contain whitespace (i.e. Unicode characters marked as whitespace)
|
||||
|
|
|
@ -876,9 +876,9 @@ SM_TARGET_TRANSFORM_EXPRESSION_ERROR = The FHIRPath expression passed as the eva
|
|||
SM_IMPORT_NOT_FOUND = No maps were found to match {0} - validation may be wrong
|
||||
SM_TARGET_TYPE_MULTIPLE_POSSIBLE = Multiple types are possible here ({0}) so further type checking is not possible
|
||||
SM_DEPENDENT_PARAM_MODE_MISMATCH = The parameter {0} refers to the variable {1} but it''s mode is {2} which is not the same as the mode required for the group {3}
|
||||
SM_DEPENDENT_PARAM_NOT_FOUND = The parameter {0} mode {1} was not found
|
||||
SM_DEPENDENT_PARAM_NOT_FOUND = The {1} parameter ''{0}'' was not found
|
||||
SM_DEPENDENT_PARAM_TYPE_MISMATCH = The parameter ''{0}'' refers to the variable ''{1}'' but it''s type is ''{2}'' which is not compatible with the type required for the group ''{3}'', which is ''{4}'' (from map ''{5}'')
|
||||
SM_ORPHAN_GROUP = The group {0} is not called from within this mapping script, and does not have types on it''s inputs, so type verification is not possible
|
||||
SM_ORPHAN_GROUP = The group {0} is not called successfully from within this mapping script, and does not have types on it''s inputs, so type verification is not possible
|
||||
SM_SOURCE_TYPE_NOT_FOUND = No source type was found, so the default group for this implied dependent rule could not be determined
|
||||
SM_TARGET_TYPE_NOT_FOUND = No target type was found, so the default group for this implied dependent rule could not be determined
|
||||
SM_MATCHING_RULEGROUP_NOT_FOUND = Unable to find a default rule for the type pair source={0} and target={1}
|
||||
|
|
Loading…
Reference in New Issue