From 62140fefc992090a8c0bf6e50e8d48cf15a41f00 Mon Sep 17 00:00:00 2001 From: vladislavploaia Date: Wed, 14 Jan 2026 11:24:25 +0200 Subject: [PATCH 1/3] feat: add Robot test to cover CDR-2181 --- ...a_main_flow_delete_event_COMPOSITION.robot | 28 ++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot b/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot index 8b558176..8983d58f 100644 --- a/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot +++ b/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot @@ -29,7 +29,7 @@ Force Tags *** Test Cases *** -Main flow delete event COMPOSITION +1. Main flow delete event COMPOSITION Upload OPT minimal/minimal_observation.opt @@ -47,3 +47,29 @@ Main flow delete event COMPOSITION get deleted composition [Teardown] Run Keywords (admin) delete ehr AND (admin) delete all OPTs + +2. Create Update Delete Composition And Check Time Committed + [Documentation] Covers bug https://vitagroup-ag.atlassian.net/browse/CDR-2181 + Upload OPT minimal/minimal_observation.opt + + create EHR + + commit composition (JSON) minimal/minimal_observation.composition.participations.extdatetimes.xml + check content of composition (JSON) + get composition - latest version JSON + Set Test Variable ${create_compo_commit_audit_datetime} ${response.json()['commit_audit']['time_committed']['value']} + Should Be Equal ${response.json()['commit_audit']['change_type']['value']} creation + Sleep 1s + update composition (JSON) minimal/minimal_observation.composition.participations.extdatetimes.v2.xml + check content of updated composition (JSON) + get composition - latest version JSON + Set Test Variable ${update_compo_commit_audit_datetime} ${response.json()['commit_audit']['time_committed']['value']} + Should Be Equal ${response.json()['commit_audit']['change_type']['value']} modification + Sleep 1s + delete composition ${composition_uid_v2} + get composition - latest version JSON + Set Test Variable ${delete_compo_commit_audit_datetime} ${response.json()['commit_audit']['time_committed']['value']} + Should Be Equal ${response.json()['commit_audit']['change_type']['value']} deleted + Should Be True '${create_compo_commit_audit_datetime}' != '${update_compo_commit_audit_datetime}' + Should Be True '${update_compo_commit_audit_datetime}' != '${delete_compo_commit_audit_datetime}' + [Teardown] Run Keywords (admin) delete ehr AND (admin) delete all OPTs From d901e828903e0d4b9e72e93cbe5b6578a4e8f4ab Mon Sep 17 00:00:00 2001 From: vladislavploaia Date: Wed, 14 Jan 2026 11:33:12 +0200 Subject: [PATCH 2/3] fix: add check for created_compo_timestamp and deleted_compo_timestamp --- .../B.8.a_main_flow_delete_event_COMPOSITION.robot | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot b/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot index 8983d58f..a7ccda4c 100644 --- a/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot +++ b/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot @@ -72,4 +72,5 @@ Force Tags Should Be Equal ${response.json()['commit_audit']['change_type']['value']} deleted Should Be True '${create_compo_commit_audit_datetime}' != '${update_compo_commit_audit_datetime}' Should Be True '${update_compo_commit_audit_datetime}' != '${delete_compo_commit_audit_datetime}' + Should Be True '${create_compo_commit_audit_datetime}' != '${delete_compo_commit_audit_datetime}' [Teardown] Run Keywords (admin) delete ehr AND (admin) delete all OPTs From 7b4386783602052614a61f05cbb3497024ebec92 Mon Sep 17 00:00:00 2001 From: vladislavploaia Date: Wed, 14 Jan 2026 11:38:49 +0200 Subject: [PATCH 3/3] fix: decrease sleep time --- .../B.8.a_main_flow_delete_event_COMPOSITION.robot | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot b/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot index a7ccda4c..14c88bf5 100644 --- a/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot +++ b/tests/robot/COMPOSITION_TESTS/DELETE_COMPOSITION/B.8.a_main_flow_delete_event_COMPOSITION.robot @@ -59,13 +59,13 @@ Force Tags get composition - latest version JSON Set Test Variable ${create_compo_commit_audit_datetime} ${response.json()['commit_audit']['time_committed']['value']} Should Be Equal ${response.json()['commit_audit']['change_type']['value']} creation - Sleep 1s + Sleep 0.5s update composition (JSON) minimal/minimal_observation.composition.participations.extdatetimes.v2.xml check content of updated composition (JSON) get composition - latest version JSON Set Test Variable ${update_compo_commit_audit_datetime} ${response.json()['commit_audit']['time_committed']['value']} Should Be Equal ${response.json()['commit_audit']['change_type']['value']} modification - Sleep 1s + Sleep 0.5s delete composition ${composition_uid_v2} get composition - latest version JSON Set Test Variable ${delete_compo_commit_audit_datetime} ${response.json()['commit_audit']['time_committed']['value']}