FHIR Frog AU Core Conformance Tests
0.1.0 - draft

FHIR Frog AU Core Conformance Tests, published by FHIR Frog. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/jgsuess/au-core-tests/ and changes regularly. See the Directory of published versions

AU Core Immunization

AU Core Immunization — SHALL-level conformance plus vaccineCode slice coverage

Covers the SHALL-level AU Core Immunization (2.0.0) requirements: read, search by patient, the SHALL search-combo patient+status, must-support element presence (including FHIRPath presence checks for the vaccineCode.coding:amtVaccineCode and vaccineCode.coding:airVaccineCode slices), and profile conformance validation. Reuses the shared au-core-patient-conformant fixture for the patient reference. Mirrors the SHALL subset of au-fhir-core-inferno's ImmunizationGroup (immunization_read_test, immunization_patient_search_test, immunization_patient_status_search_test, immunization_must_support_test, immunization_validation_test). Also includes standalone (MAY-level) SearchByDate and SearchByVaccineCode tests since date/status/vaccine-code/patient search were explicitly named in fhirfrog/au-core-compiler#11 — following the precedent set in #7/#8 of demonstrating an explicitly-called-out MAY/SHOULD-level mechanism alongside the SHALL-only core. The remaining SHOULD/MAY-level combinatorial coverage (patient+date, patient+vaccine-code, vaccine-code multiple-or, date multiple-and, the DVA/IHI/Medicare patient identifier chain searches, and the reference-resolution test) is not replicated here; see fhirfrog/au-core-compiler#6 for the original SHALL-only scope rationale. The amtVaccineCode and airVaccineCode slices are discriminated in the AU Core StructureDefinition by a pattern/$this rule bound to the amt-vaccine-1 and australian-immunisation-register-vaccine-1 ValueSets respectively rather than by a fixed coding.system element; in practice AMT codes are carried on the http://snomed.info/sct system and AIR codes on the https://www.humanservices.gov.au/organisations/health-professionals/enablers/air-vaccine-code-formats system (confirmed against the published au-core-immunization example Immunization-covid-1), so slice presence is asserted via a coding.where(system=...) FHIRPath check against those two systems.

Name
AUCoreImmunization
URL
http://fhirfrog.org/fhir/au-core-tests/TestScript/au-core-immunization
Status
active

Fixtures

  • patient-fixture: au-core-patient-conformant (created before, and removed after, the run)
  • immunization-fixture: au-core-immunization-conformant (created before, and removed after, the run)

Variables

  • ${patientId} = Patient.id of patient-fixture
  • ${immunizationId} = Immunization.id of immunization-fixture

Read

  1. Read Immunization by id (${immunizationId}) READ Immunization/${immunizationId}
  2. Response status is okay response = okay

SearchByPatient

  1. Search Immunization where patient = ${patientId} SEARCH Immunization?patient=${patientId}
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Immunization).note.text.where($this.contains('Frog')).exists() expression = Bundle.entry.resource.ofType(Immunization).note.text.where($this.contains('Frog')).exists()

SearchByPatientAndStatus

  1. Search Immunization where patient = ${patientId} and status = completed SEARCH Immunization?patient=${patientId}&status=completed
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Immunization).status.where($this = 'completed').exists() expression = Bundle.entry.resource.ofType(Immunization).status.where($this = 'completed').exists()

SearchByDate

  1. Search Immunization where date = ge2020-01-01 SEARCH Immunization?date=ge2020-01-01
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Immunization).note.text.exists($this.contains('Frog')) expression = Bundle.entry.resource.ofType(Immunization).note.text.exists($this.contains('Frog'))

SearchByVaccineCode

  1. Search Immunization where vaccine-code = https://www.humanservices.gov.au/organisations/health-professionals/enablers/air-vaccine-code-formats|COMIRN SEARCH Immunization?vaccine-code=https://www.humanservices.gov.au/organisations/health-professionals/enablers/air-vaccine-code-formats|COMIRN
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Immunization).vaccineCode.coding.where(code = 'COMIRN').exists() expression = Bundle.entry.resource.ofType(Immunization).vaccineCode.coding.where(code = 'COMIRN').exists()

MustSupport

  1. Read Immunization by id (${immunizationId}) READ Immunization/${immunizationId}
  2. Check: Immunization.status.exists() expression = Immunization.status.exists()
  3. Check: Immunization.vaccineCode.exists() expression = Immunization.vaccineCode.exists()
  4. Check: Immunization.vaccineCode.coding.where(system = 'http://snomed.info/sct').exists() expression = Immunization.vaccineCode.coding.where(system = 'http://snomed.info/sct').exists()
  5. Check: Immunization.vaccineCode.coding.where(system = 'https://www.humanservices.gov.au/organisations/health-professionals/enablers/air-vaccine-code-formats').exists() expression = Immunization.vaccineCode.coding.where(system = 'https://www.humanservices.gov.au/organisations/health-professionals/enablers/air-vaccine-code-formats').exists()
  6. Check: Immunization.patient.exists() expression = Immunization.patient.exists()
  7. Check: Immunization.occurrence.ofType(dateTime).exists() expression = Immunization.occurrence.ofType(dateTime).exists()
  8. Check: Immunization.primarySource.exists() expression = Immunization.primarySource.exists()
  9. Check: Immunization.lotNumber.exists() expression = Immunization.lotNumber.exists()
  10. Check: Immunization.note.exists() expression = Immunization.note.exists()

ProfileValidation

  1. Read Immunization by id (${immunizationId}) READ Immunization/${immunizationId}
  2. Validate the response against profile http://hl7.org.au/fhir/core/StructureDefinition/au-core-immunization validateProfileId = http://hl7.org.au/fhir/core/StructureDefinition/au-core-immunization