Addressed failures
This commit is contained in:
parent
fd90eb699f
commit
b503d50b67
|
@ -132,7 +132,7 @@ public class GoldenResourceMergerSvcImpl implements IGoldenResourceMergerSvc {
|
||||||
break;
|
break;
|
||||||
case MANUAL:
|
case MANUAL:
|
||||||
if (fromLink.getMatchResult() != toLink.getMatchResult()) {
|
if (fromLink.getMatchResult() != toLink.getMatchResult()) {
|
||||||
throw new InvalidRequestException("A MANUAL " + fromLink.getMatchResult() + " link may not be merged into a MANUAL " + toLink.getMatchResult() + " link for the same source resource");
|
throw new InvalidRequestException("A MANUAL " + fromLink.getMatchResult() + " link may not be merged into a MANUAL " + toLink.getMatchResult() + " link for the same target");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -122,7 +122,7 @@ public class MdmProviderQueryLinkR4Test extends BaseLinkR4Test {
|
||||||
assertThat(thePart, hasSize(theExpectedSize));
|
assertThat(thePart, hasSize(theExpectedSize));
|
||||||
assertThat(thePart.get(0).getName(), is("goldenResourceId"));
|
assertThat(thePart.get(0).getName(), is("goldenResourceId"));
|
||||||
assertThat(thePart.get(0).getValue().toString(), is(removeVersion(theGoldenResourceId)));
|
assertThat(thePart.get(0).getValue().toString(), is(removeVersion(theGoldenResourceId)));
|
||||||
assertThat(thePart.get(1).getName(), is("targetResourceId"));
|
assertThat(thePart.get(1).getName(), is("sourceResourceId"));
|
||||||
assertThat(thePart.get(1).getValue().toString(), is(removeVersion(theTargetId)));
|
assertThat(thePart.get(1).getValue().toString(), is(removeVersion(theTargetId)));
|
||||||
if (theExpectedSize > 2) {
|
if (theExpectedSize > 2) {
|
||||||
assertThat(thePart.get(2).getName(), is("matchResult"));
|
assertThat(thePart.get(2).getName(), is("matchResult"));
|
||||||
|
|
|
@ -160,7 +160,7 @@ public class MdmProviderUpdateLinkR4Test extends BaseLinkR4Test {
|
||||||
myMdmProviderR4.updateLink(mySourcePatientId, new StringType(patient.getIdElement().getValue()), NO_MATCH_RESULT, myRequestDetails);
|
myMdmProviderR4.updateLink(mySourcePatientId, new StringType(patient.getIdElement().getValue()), NO_MATCH_RESULT, myRequestDetails);
|
||||||
fail();
|
fail();
|
||||||
} catch (InvalidRequestException e) {
|
} catch (InvalidRequestException e) {
|
||||||
assertEquals("The target is marked with the " + MdmConstants.CODE_NO_MDM_MANAGED + " tag which means it may not be MDM linked.", e.getMessage());
|
assertEquals(myMessageHelper.getMessageForUnsupportedSourceResource(), e.getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue