Scalable Consent Management Testing Guide
1.0.0-ballot - ci-build United States of America flag

Scalable Consent Management Testing Guide - Local Development build (v1.0.0-ballot) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions

TestScript: 01 Read Simple Search - All SUT | 04 Search for an AuditEvent

Official URL: http://hl7.org/fhir/us/consent-management-tg/TestScript/04-Search-for-an-AuditEvent Version: 1.0.0-ballot
Standards status: Trial-use Maturity Level: 1 Computable Name: Test_04_Search_for_an_AuditEvent

Copyright/Legal: (c) AEGIS.net, Inc. 2026

Test a client and server to verify support for the AuditEvent search interaction and the return of at least one valid AuditEvent resource conforming to the FASTConsentAuditEvent profile. This scenario is generic and can be used with any FHIR format and query parameters. Test case supporting the FAST Consent Management IG Version: CI. See https://wildfhir4.wildfhir.org/ig/fhir-consent-management-tg/rtm_test_cases.html#testcase-142 Test System Details (in order of appearance): [Origin 1: Consent Client's RESTful client. System Under Test: this must be an external test system (not Touchstone).] [Destination 1: Consent Admin Service's RESTful FHIR Server. System Under Test: this must be an external test system (not a mock).]

AEGIS Touchstone Testing TestScript Rule Extension

  • ruleId: AssertBodyExists
  • path: /FHIRCommon/_reference/rule/AssertBodyExists.groovy

StructureDefinition Work Group: cbcc

url: TestScript 01 Read Simple Search - All SUT | 04 Search for an AuditEvent

version: 1.0.0-ballot

name: Test_04_Search_for_an_AuditEvent

title: 01 Read Simple Search - All SUT | 04 Search for an AuditEvent

status: Active

date: 2026-03-30

publisher: HL7 International / Community Based Collaborative Care

contact: HL7 International / Community Based Collaborative Care: http://www.hl7.org/Special/committees/cbcc

description:

Test a client and server to verify support for the AuditEvent search interaction and the return of at least one valid AuditEvent resource conforming to the FASTConsentAuditEvent profile. This scenario is generic and can be used with any FHIR format and query parameters. Test case supporting the FAST Consent Management IG Version: CI. See https://wildfhir4.wildfhir.org/ig/fhir-consent-management-tg/rtm_test_cases.html#testcase-142 Test System Details (in order of appearance): [Origin 1: Consent Client's RESTful client. System Under Test: this must be an external test system (not Touchstone).] [Destination 1: Consent Admin Service's RESTful FHIR Server. System Under Test: this must be an external test system (not a mock).]

jurisdiction: United States of America

copyright:

(c) AEGIS.net, Inc. 2026

Origins

-IndexProfile
*1Test script profile origin type: FHIR-Client (FHIR Client)

Destinations

-IndexProfile
*1Test script profile destination type: FHIR-Server (FHIR Server)

profile: http://hl7.org/fhir/StructureDefinition/Bundle

test

name: Step_001_AuditEvent_search

description: Consent Client searches for AuditEvent resources at Consent Admin Service.

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginRequestIdResponseId
*Test script operation code: search (Search)AuditEventSearch for AuditEvent resources.1true1dest-1-FHIRSearch-1-requestdest-1-FHIRSearch-1-response

action

Asserts

-ExtensionDescriptionDirectionOperatorResponseCodeSourceIdWarningOnly
*Confirm that the returned HTTP status is 200 OK.responsein200dest-1-FHIRSearch-1-responsefalse

action

Asserts

-ExtensionDescriptionDirectionWarningOnly
*Confirm that the response body exists.responsefalse

action

Asserts

-ExtensionDescriptionDirectionResourceWarningOnly
*Confirm that the response resource type is Bundle.responseBundlefalse

action

Asserts

-ExtensionDescriptionDirectionValidateProfileIdWarningOnly
*Confirm that the response Bundle conforms to the base FHIR Bundle profile. This also validates the contents against any declared profiles.responseBundle-profilefalse

action

Asserts

-ExtensionDescriptionDirectionExpressionOperatorValueWarningOnly
*Confirm that the response Bundle type is searchset.responseBundle.typeequalssearchsetfalse

action

Asserts

-ExtensionDescriptionDirectionExpressionOperatorSourceIdValueWarningOnly
*Confirm that at least one AuditEvent resource is in the response.responseBundle.entry.select(resource as AuditEvent).exists()equalsdest-1-FHIRSearch-1-responsetruefalse

action

Asserts

-ExtensionDescriptionDirectionExpressionOperatorSourceIdValueWarningOnly
*Confirm that at least one AuditEvent resource in the response declares the FASTConsentAuditEvent profile.responseBundle.entry.select(resource as AuditEvent).where('http://hl7.org/fhir/us/consent-management/StructureDefinition/FASTConsentAuditEvent' in meta.profile).exists()equalsdest-1-FHIRSearch-1-responsetruefalse