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 Condition

AU Core Condition — SHALL-level conformance

Covers the SHALL-level AU Core Condition (2.0.0) requirements: read, search by patient, the SHALL search-combos patient+category and patient+clinical-status, must-support element presence, and profile conformance validation, plus one SHOULD search-combo (patient+code) included to demonstrate the multi-param querystring pattern. Mirrors the SHALL subset of au-fhir-core-inferno's ConditionGroup (condition_read_test, condition_patient_search_test, condition_patient_category_search_test, condition_patient_clinical_status_search_test, condition_must_support_test, condition_validation_test). The remaining SHOULD/MAY-level combinatorial search tests (patient+category+clinical-status, patient+onset-date, code with multiple-or, onset-date with multiple-and, the DVA/IHI/Medicare identifier chain searches on patient, and the reference-resolution test) are not replicated here, per the same SHALL-only scope rationale used for Patient; see fhirfrog/au-core-compiler#6 and #8.

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

Fixtures

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

Variables

  • ${patientId} = Patient.id of patient-fixture
  • ${conditionId} = Condition.id of condition-fixture

Read

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

SearchByPatient

  1. Search Condition where patient = ${patientId} SEARCH Condition?patient=${patientId}
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Condition).where(code.coding.code = '68566005').exists() expression = Bundle.entry.resource.ofType(Condition).where(code.coding.code = '68566005').exists()

SearchByPatientAndCategory

  1. Search Condition where patient = ${patientId} and category = http://terminology.hl7.org/CodeSystem/condition-category|problem-list-item SEARCH Condition?patient=${patientId}&category=http://terminology.hl7.org/CodeSystem/condition-category|problem-list-item
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Condition).where(category.coding.code = 'problem-list-item').exists() expression = Bundle.entry.resource.ofType(Condition).where(category.coding.code = 'problem-list-item').exists()

SearchByPatientAndClinicalStatus

  1. Search Condition where patient = ${patientId} and clinical-status = http://terminology.hl7.org/CodeSystem/condition-clinical|resolved SEARCH Condition?patient=${patientId}&clinical-status=http://terminology.hl7.org/CodeSystem/condition-clinical|resolved
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Condition).where(clinicalStatus.coding.code = 'resolved').exists() expression = Bundle.entry.resource.ofType(Condition).where(clinicalStatus.coding.code = 'resolved').exists()

SearchByPatientAndCode

  1. Search Condition where patient = ${patientId} and code = http://snomed.info/sct|68566005 SEARCH Condition?patient=${patientId}&code=http://snomed.info/sct|68566005
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(Condition).where(code.coding.code = '68566005').exists() expression = Bundle.entry.resource.ofType(Condition).where(code.coding.code = '68566005').exists()

MustSupport

  1. Read Condition by id (${conditionId}) READ Condition/${conditionId}
  2. Check: Condition.clinicalStatus.exists() expression = Condition.clinicalStatus.exists()
  3. Check: Condition.verificationStatus.exists() expression = Condition.verificationStatus.exists()
  4. Check: Condition.category.exists() expression = Condition.category.exists()
  5. Check: Condition.severity.exists() expression = Condition.severity.exists()
  6. Check: Condition.code.exists() expression = Condition.code.exists()
  7. Check: Condition.subject.exists() expression = Condition.subject.exists()
  8. Check: Condition.onset.exists() expression = Condition.onset.exists()
  9. Check: Condition.abatement.exists() expression = Condition.abatement.exists()
  10. Check: Condition.note.exists() expression = Condition.note.exists()

ProfileValidation

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