Serenity BDD Report
Home > Requirements > Stufe5 > Terminplanung > Testing search parameters against the healthcareservice resource (@healthcareservice-search)
Report generated 23-03-2026 09:39

Feature: Testing search parameters against the healthcareservice resource (@healthcareservice-search)

Scenarios

Given the Test Description: "The system under test MUST return the created resource correctly and completely in response to an HTTP GET request to its URL (READ)."

Given the Preconditions: - The HealthcareService-Read test case must have been executed successfully beforehand.

Then Get FHIR resource at "http://fhirserver/metadata" with content type "json"

And CapabilityStatement contains interaction "search-type" for resource "HealthcareService"

And CapabilityStatement contains definition of search parameter "{searchParamValue}" of type "{searchParamType}" for resource "HealthcareService"

Examples:

searchParamValuesearchParamType
_idtoken
_countnumber
activetoken
service-typetoken
specialtytoken
namestring

Examples:

searchParamValuesearchParamType
_tagtoken 

Then Get FHIR resource at "http://fhirserver/HealthcareService/?_id=${data.healthcareservice-read-id}" with content type "xml"

And response bundle contains resource with ID "${data.healthcareservice-read-id}" with error message "The requested HealthcareService ${data.healthcareservice-read-id} is not contained in the response bundle"

And FHIR current response body is a valid CORE resource and conforms to profile "https://hl7.org/fhir/StructureDefinition/Bundle"

And Check if current response of resource "HealthcareService" is valid isik5 resource and conforms to profile "https://gematik.de/fhir/isik/StructureDefinition/ISiKMedizinischeBehandlungseinheit"

When Get FHIR resource at "http://fhirserver/HealthcareService/?_tag=${data.tag-system}%7C${data.tag-value}" with content type "xml"

And FHIR current response body evaluates the FHIRPath 'entry.resource.count() } 0' with error message 'No search results were found'

And FHIR current response body evaluates the FHIRPath "entry.resource.all(meta.tag.where(code='${data.tag-value}').exists())" with error message 'There are search results, but they do not fully match the search criteria'

When Get FHIR resource at "http://fhirserver/HealthcareService/?_count" with content type "xml"

And FHIR current response body evaluates the FHIRPath 'total } 0 and entry.resource.count() } 0' with error message 'No search results were found'

Then Get FHIR resource at "http://fhirserver/HealthcareService/?active=true" with content type "json"

And FHIR current response body evaluates the FHIRPath 'entry.resource.ofType(HealthcareService).count() } 0' with error message 'No search results were found'

And FHIR current response body evaluates the FHIRPath "entry.resource.ofType(HealthcareService).all(active = 'true')" with error message 'There are search results, but they do not fully match the search criteria.'

Then Get FHIR resource at "http://fhirserver/HealthcareService/?{searchParameter}={searchValue}" with content type "json"

And FHIR current response body evaluates the FHIRPath 'entry.resource.ofType(HealthcareService).count() } 0' with error message 'No search results were found'

And FHIR current response body evaluates the FHIRPath "entry.resource.ofType(HealthcareService).all({coding}.coding.where(code='{searchValue}').exists())" with error message 'There are search results, but they do not fully match the search criteria.'

Examples:

searchParametercodingsearchValue
service-typetype${data.healthcareservice-read-servicetype-code}

Then Get FHIR resource at "http://fhirserver/HealthcareService/?specialty=urn%3Aoid%3A1.2.276.0.76.5.114%7C142%2Chttp%3A%2F%2Fihe-d.de%2FCodeSystems%2FAerztlicheFachrichtungen%7CNEUR" with content type "json"

And FHIR current response body evaluates the FHIRPath 'entry.resource.ofType(HealthcareService).count() } 0' with error message 'No search results were found'

And FHIR current response body evaluates the FHIRPath "entry.resource.ofType(HealthcareService).all(specialty.coding.where((code = '142' and system ='urn:oid:1.2.276.0.76.5.114') or (code = 'NEUR' and system ='http://ihe-d.de/CodeSystems/AerztlicheFachrichtungen' )).exists())" with error message 'There are search results, but they do not fully match the search criteria.'

Then Get FHIR resource at "http://fhirserver/HealthcareService/?name=${data.healthcareservice-search-name}" with content type "xml"

And FHIR current response body evaluates the FHIRPath 'entry.resource.ofType(HealthcareService).count() } 0' with error message 'No search results were found'

And FHIR current response body evaluates the FHIRPath "entry.resource.ofType(HealthcareService).all(name.contains('${data.healthcareservice-read-name}'))" with error message 'There are search results, but they do not fully match the search criteria.'

Feature Coverage By Scenario

Test Outcomes

Test Performance

Key Statistics

Number of Scenarios 9 Total Duration 8s
Total Number of Test Cases 14 Fastest Test 217ms
Number of Manual Test Cases 0 Slowest Test 1s
Tests Started März 23, 2026 09:39:27 Average Execution Time 610ms
Tests Finished März 23, 2026 09:39:35 Total Execution Time 8s

Automated Tests

feature Scenario Context Steps Started Total Duration Result
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Precondition 2 09:39:27 427ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Read and Validation of the CapabilityStatement 2 09:39:27 719ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Validation of the search parameter definitions in the CapabilityStatement
6 passing test cases
1 09:39:28 1s 363ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by ID 4 09:39:29 1s 142ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by Tag 3 UNDEFINED
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by Count 2 09:39:30 704ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by Active state 3 09:39:31 999ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by service type
1 passing test case
3 09:39:32 991ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by Specialty 3 09:39:33 1s 228ms SUCCESS
Testing search parameters against the HealthcareService resource (@HealthcareService-Search) Search for the HealthcareService by Name 3 09:39:34 1s 022ms SUCCESS

Manual Tests

No manual tests were recorded
Serenity BDD version 4.3.2