diff --git a/src/processor/InstanceProcessor.ts b/src/processor/InstanceProcessor.ts index 5eac448..d263e57 100644 --- a/src/processor/InstanceProcessor.ts +++ b/src/processor/InstanceProcessor.ts @@ -114,7 +114,7 @@ export class InstanceProcessor { i, flatInstanceArray, instanceOfJSON.type, - target.id, + `${target.instanceOf} ${target.id}`, fisher ); // if the value is empty, we can't use that diff --git a/test/extractor/CaretValueRuleExtractor.test.ts b/test/extractor/CaretValueRuleExtractor.test.ts index 053a804..3f56a54 100644 --- a/test/extractor/CaretValueRuleExtractor.test.ts +++ b/test/extractor/CaretValueRuleExtractor.test.ts @@ -1076,13 +1076,13 @@ describe('CaretValueRuleExtractor', () => { const element = ProcessableElementDefinition.fromJSON(looseSD.differential.element[12]); const caretRules = CaretValueRuleExtractor.process(element, looseSD, defs); const expectedRule = new ExportableCaretValueRule('component.valueDateTime'); - expectedRule.caretPath = 'patternDateTime'; + expectedRule.caretPath = 'minValueDateTime'; expectedRule.value = '2013-01-01 00:00:00.000'; expect(caretRules).toHaveLength(1); expect(caretRules[0]).toEqual(expectedRule); expect(loggerSpy.getAllMessages('warn')).toHaveLength(1); expect(loggerSpy.getLastMessage('warn')).toMatch( - /Value 2013-01-01 00:00:00\.000 on ObservationWithCaret\.component\.valueDateTime element patternDateTime is not a valid FHIR dateTime/s + /Value 2013-01-01 00:00:00\.000 on ObservationWithCaret\.component\.valueDateTime element minValueDateTime is not a valid FHIR dateTime/s ); }); }); diff --git a/test/extractor/fixtures/caret-value-profile.json b/test/extractor/fixtures/caret-value-profile.json index ea165ed..02eeae4 100644 --- a/test/extractor/fixtures/caret-value-profile.json +++ b/test/extractor/fixtures/caret-value-profile.json @@ -175,7 +175,7 @@ { "id": "Observation.component.valueDateTime", "path": "Observation.component.valueDateTime", - "patternDateTime": "2013-01-01 00:00:00.000" + "minValueDateTime": "2013-01-01 00:00:00.000" } ] } diff --git a/test/processor/InstanceProcessor.test.ts b/test/processor/InstanceProcessor.test.ts index 2751fd2..6e0194a 100644 --- a/test/processor/InstanceProcessor.test.ts +++ b/test/processor/InstanceProcessor.test.ts @@ -494,7 +494,7 @@ describe('InstanceProcessor', () => { expect(result.rules).toContainEqual(birthDateRule); expect(loggerSpy.getAllMessages('warn')).toHaveLength(1); expect(loggerSpy.getLastMessage('warn')).toMatch( - /Value 1985\/07\/12 on invalid-date-patient element birthDate is not a valid FHIR date/s + /Value 1985\/07\/12 on Patient invalid-date-patient element birthDate is not a valid FHIR date/s ); });