Fix test tx frmework to handle diagnostics correctly
This commit is contained in:
parent
c9c04aec3b
commit
533142cefd
|
@ -402,6 +402,7 @@ public class TxTester {
|
|||
} catch (EFhirClientException e) {
|
||||
code = e.getCode();
|
||||
OperationOutcome oo = e.getServerError();
|
||||
TxTesterScrubbers.scrubOO(oo, tight);
|
||||
oo.setText(null);
|
||||
pj = new org.hl7.fhir.r5.formats.JsonParser().setOutputStyle(OutputStyle.PRETTY).composeString(oo);
|
||||
}
|
||||
|
|
|
@ -92,7 +92,9 @@ public class TxTesterScrubbers {
|
|||
scrubDR(po, tight);
|
||||
po.getIssue().removeIf(i -> i.hasDiagnostics() & !i.hasDetails());
|
||||
for (OperationOutcomeIssueComponent iss : po.getIssue()) {
|
||||
iss.setDiagnostics(null);
|
||||
if (iss.hasDiagnostics() && !iss.getDiagnostics().toLowerCase().contains("x-request-id")) {
|
||||
iss.setDiagnostics(null);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue