Serenity BDD Report
Home > Requirements > Stufe5 > Medikation > Update a resource of type medicationrequest (@medicationrequest-update)
Report generated 01-09-2026 07:05

Feature: Update a resource of type medicationrequest (@medicationrequest-update)

Scenarios

Given the Test Description: "The system under test MUST update an existing resource."

Given the Preconditions: - The MedicationRequest-Create test case must have been executed successfully beforehand.

  • Store the ID of any MedicationRequest resource that should be updated with test data in the configuration variable 'medicationrequest-update-id'.

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

And CapabilityStatement contains interaction "update" for resource "MedicationRequest"

Given TGR set default header "Content-Type" to "application/fhir+json"

When TGR send PUT request to "http://fhirserver/MedicationRequest/${data.medicationrequest-update-id}" with body "!{file('src/test/resources/features/Stufe5/Medikation/fixtures/MedicationRequest-Update-Fixture.json')}"

And TGR find the last request

Then TGR current response with attribute "$.responseCode" matches "20\d"

And TGR send empty GET request to "http://fhirserver/MedicationRequest/${data.medicationrequest-update-id}"

And TGR find the last request

And TGR current response with attribute "$.body.note.0.text.content" matches "Updated note"

And FHIR current response body evaluates the FHIRPath "dispenseRequest.quantity.value ~ 10" with error message 'The dispense quantity was not updated or was updated incorrectly'

And FHIR current response body evaluates the FHIRPath "substitution.allowed = false" with error message 'Substitution allowed does not match the expected value'

Feature Coverage By Scenario

Test Outcomes

Test Performance

Key Statistics

Number of Scenarios 3 Total Duration 10s
Total Number of Test Cases 3 Fastest Test 447ms
Number of Manual Test Cases 0 Slowest Test 7s
Tests Started Sep 01, 2026 07:05:38 Average Execution Time 3s
Tests Finished Sep 01, 2026 07:05:48 Cumulative Test Time
(sum of all individual test durations)
10s

Automated Tests

feature Scenario Context Steps Started Total Duration Result
Update a resource of type MedicationRequest (@MedicationRequest-Update) Precondition 2 07:05:38 447ms SUCCESS
Update a resource of type MedicationRequest (@MedicationRequest-Update) Read and Validation of the CapabilityStatement 2 07:05:39 7s 429ms SUCCESS
Update a resource of type MedicationRequest (@MedicationRequest-Update) Update a MedicationRequest resource 9 07:05:46 2s 215ms SUCCESS

Manual Tests

No manual tests were recorded

Evidence

Scenario Title Details
Precondition RBellog 0  Download Evidence
Read and Validation of the CapabilityStatement INFO - rest.where(mode = 'server').resource.where(type = 'MedicationRequest' and interaction.where(code = 'update').exists()).exists()  Details
Read and Validation of the CapabilityStatement RBellog 0  Download Evidence
Read and Validation of the CapabilityStatement Evidence Report  Download Evidence
Update a MedicationRequest resource INFO - dispenseRequest.quantity.value ~ 10  Details
Update a MedicationRequest resource INFO - substitution.allowed = false  Details
Update a MedicationRequest resource RBellog 0  Download Evidence
Update a MedicationRequest resource Evidence Report  Download Evidence
Serenity BDD version 5.3.10