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 PractitionerRole

AU Core PractitionerRole — core search & profile conformance

Covers the AU Core PractitionerRole (2.0.0) requirements identified in fhirfrog/au-core-compiler#18: read, search by _id/identifier/practitioner/specialty/role/organization, the AU-specific chained-practitioner search (practitioner:Practitioner.identifier) combined with _include=PractitionerRole:practitioner, must-support element presence, and profile conformance validation. Mirrors au-fhir-core-inferno's PractitionerRoleGroup (practitioner_role_read_test, practitioner_role__id_search_test, practitioner_role_identifier_search_test, practitioner_role_identifier_medicare_search_test, practitioner_role_practitioner_search_test, practitioner_role_specialty_search_test, practitioner_role_role_search_test, practitioner_role_organization_search_test, practitioner_role_practitioner_chain_search_test, practitioner_role_practitioner_include_practitioner_test, practitioner_role_must_support_test, practitioner_role_validation_test). Issue #18's premise is that the chained-practitioner SearchParameter and the Medicare identifier search are plain query-string parameters that fhir-frog's byUrl-pass-through search executor already handles generically, so this TestScript exercises each as a single representative query rather than replicating Inferno's full SHOULD/MAY combinatorial variants (GET/POST comparison, multiple AND/OR reference forms, reference-form-only variants) — see fhirfrog/au-core-compiler#6 for the equivalent Patient-level scope rationale. The identifier fixture carries a Medicare-provider-number-typed identifier so the plain identifier search doubles as the Medicare identifier search. Per the Bundle-validation-gap caveat noted on fhirfrog/au-core-compiler#14, validateProfileId is not attempted against the _include'd search Bundle; PractitionerRole profile conformance is instead checked via a separate plain read.

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

Fixtures

  • practitionerrole-practitioner-fixture: au-core-practitionerrole-practitioner (created before, and removed after, the run)
  • practitionerrole-organization-fixture: au-core-practitionerrole-organization (created before, and removed after, the run)
  • practitionerrole-fixture: au-core-practitionerrole-conformant (created before, and removed after, the run)

Variables

  • ${practitionerRoleId} = PractitionerRole.id of practitionerrole-fixture
  • ${practitionerId} = Practitioner.id of practitionerrole-practitioner-fixture
  • ${organizationId} = Organization.id of practitionerrole-organization-fixture

Read

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

SearchById

  1. Search PractitionerRole where _id = ${practitionerRoleId} SEARCH PractitionerRole?_id=${practitionerRoleId}
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists() expression = Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists()

SearchByIdentifier

  1. Search PractitionerRole where identifier = http://ns.electronichealth.net.au/id/medicare-provider-number|2449001X SEARCH PractitionerRole?identifier=http://ns.electronichealth.net.au/id/medicare-provider-number|2449001X
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).identifier.value.where($this = '2449001X').exists() expression = Bundle.entry.resource.ofType(PractitionerRole).identifier.value.where($this = '2449001X').exists()

SearchByPractitioner

  1. Search PractitionerRole where practitioner = Practitioner/${practitionerId} SEARCH PractitionerRole?practitioner=Practitioner/${practitionerId}
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists() expression = Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists()

SearchBySpecialty

  1. Search PractitionerRole where specialty = http://snomed.info/sct|408443003 SEARCH PractitionerRole?specialty=http://snomed.info/sct|408443003
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).specialty.coding.code.where($this = '408443003').exists() expression = Bundle.entry.resource.ofType(PractitionerRole).specialty.coding.code.where($this = '408443003').exists()

SearchByRole

  1. Search PractitionerRole where role = http://snomed.info/sct|62247001 SEARCH PractitionerRole?role=http://snomed.info/sct|62247001
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists() expression = Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists()

SearchByOrganization

  1. Search PractitionerRole where organization = Organization/${organizationId} SEARCH PractitionerRole?organization=Organization/${organizationId}
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists() expression = Bundle.entry.resource.ofType(PractitionerRole).code.coding.code.where($this = '62247001').exists()

ChainedPractitionerIncludePractitioner

  1. Search PractitionerRole where practitioner:Practitioner.identifier = http://ns.electronichealth.net.au/id/hi/hpii/1.0|8003614900041692 and _include = PractitionerRole:practitioner SEARCH PractitionerRole?practitioner:Practitioner.identifier=http://ns.electronichealth.net.au/id/hi/hpii/1.0|8003614900041692&_include=PractitionerRole:practitioner
  2. Response status is okay response = okay
  3. Check: Bundle.entry.resource.ofType(PractitionerRole).exists() expression = Bundle.entry.resource.ofType(PractitionerRole).exists()
  4. Check: Bundle.entry.resource.ofType(Practitioner).name.family.where($this.contains('Frog')).exists() expression = Bundle.entry.resource.ofType(Practitioner).name.family.where($this.contains('Frog')).exists()

MustSupport

  1. Read PractitionerRole by id (${practitionerRoleId}) READ PractitionerRole/${practitionerRoleId}
  2. Check: PractitionerRole.identifier.exists() expression = PractitionerRole.identifier.exists()
  3. Check: PractitionerRole.practitioner.exists() expression = PractitionerRole.practitioner.exists()
  4. Check: PractitionerRole.organization.exists() expression = PractitionerRole.organization.exists()
  5. Check: PractitionerRole.code.exists() expression = PractitionerRole.code.exists()
  6. Check: PractitionerRole.specialty.exists() expression = PractitionerRole.specialty.exists()
  7. Check: PractitionerRole.telecom.exists() expression = PractitionerRole.telecom.exists()
  8. Check: PractitionerRole.telecom.system.exists() expression = PractitionerRole.telecom.system.exists()
  9. Check: PractitionerRole.telecom.value.exists() expression = PractitionerRole.telecom.value.exists()

ProfileValidation

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