From ee42983bc91fbd7db8d1455a8f5b31e9e5745635 Mon Sep 17 00:00:00 2001
From: reinaortega <miguelangel.reinaortega@etsi.org>
Date: Wed, 7 Oct 2020 15:41:11 +0200
Subject: [PATCH] Correction for TC_CSE_SUB_NTF_003

Signed-off-by: reinaortega <miguelangel.reinaortega@etsi.org>
---
 OneM2M_Testcases_CSE_Release_2.ttcn | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/OneM2M_Testcases_CSE_Release_2.ttcn b/OneM2M_Testcases_CSE_Release_2.ttcn
index 1d5c8c8..28a252f 100644
--- a/OneM2M_Testcases_CSE_Release_2.ttcn
+++ b/OneM2M_Testcases_CSE_Release_2.ttcn
@@ -2447,6 +2447,25 @@ module OneM2M_Testcases_CSE_Release_2 {
 							v_responsePrimitive.requestIdentifier := vc_request.primitive.requestPrimitive.requestIdentifier;
 							f_send(e_mcaPortIn, m_response(v_responsePrimitive));
 							
+						}
+						[] mcaPortIn.receive(mw_request(mw_notifyAggregatedNotification({{mw_contentNotification(?)}}))) -> value vc_request {
+							tc_ac.stop;
+							if(f_check_notificationContent(vc_request.primitive.requestPrimitive, v_contentResponse)){
+								setverdict(pass, __SCOPE__ & ":INFO: Notification received");
+								v_elapsedTime := t_batchNotificationTimer.read;
+								t_batchNotificationTimer.stop;
+								if(v_elapsedTime < 10.0) {
+									setverdict(fail, __SCOPE__ & ": Notifications sent before bathNotify/duration expired");
+								}
+							}
+							else{
+								setverdict(fail, __SCOPE__ & ":ERROR: Notification received but the content doesn't match");
+							}
+							//Send response in any case
+							v_responsePrimitive := valueof(m_responseNotification(int2000, omit));
+							v_responsePrimitive.requestIdentifier := vc_request.primitive.requestPrimitive.requestIdentifier;
+							f_send(e_mca_in_port, m_response(v_responsePrimitive));
+							
 						}
 						[] tc_ac.timeout {
 							setverdict(fail, __SCOPE__ & ": No notification received");
-- 
GitLab