diff --git a/OneM2M_Testcases_CSE.ttcn b/OneM2M_Testcases_CSE.ttcn index 4fcb88d4fe03bf8d2ce92a7ae134234881324676..c1ecb91fed109ae606d117cb3390eaa6d5c44c79 100644 --- a/OneM2M_Testcases_CSE.ttcn +++ b/OneM2M_Testcases_CSE.ttcn @@ -3222,6 +3222,10 @@ module OneM2M_Testcases_CSE { }//end f_CSE_REG_UPD_002 } //end g_CSE_REG_UPD_002 + /** + * @desc Check that IUT sends a <remoteCSE> update request with OPTIONAL_ATTRIBUTE attribute. + * + */ group g_CSE_REG_UPD_003 { testcase TC_CSE_REG_UPD_003_ET() runs on Tester system CseSystem { @@ -3301,8 +3305,7 @@ module OneM2M_Testcases_CSE { var RequestPrimitive v_request; var ResourceType v_resourceType := int16; //remoteCSE var template UtTriggerPrimitive v_utRequest := m_utCreateRemoteCSE; - var charstring v_action := __SCOPE__ & ": Please, send a valid RETRIEVE Request containing To set to " & PX_CSE1_ADDRESS & " and Content containing remoteCSE resource containing a valid attribute " & p_attribute[0]; - // Test control + var charstring v_action := __SCOPE__ & ": Please, send a valid UPDATE Request containing To set to " & PX_CSE1_ADDRESS & " and Content containing remoteCSE resource containing a valid attribute " & p_attribute[0]; // Test control if(not(PICS_MN_CSE)) { setverdict(inconc, __SCOPE__ & ": IUT shall be MN-CSE to run this test case"); stop; @@ -3324,27 +3327,16 @@ module OneM2M_Testcases_CSE { // Test Body v_request := f_getUpdateRequestPrimitive(int16, vc_remoteCseIndex, p_requestPrimitive); - mccPort.send(m_request(v_request)); tc_ac.start; alt { - [] mccPort.receive(mw_response(mw_responsePrimitive(int2004, f_getTemplateFromPrimitiveContent(v_request.primitiveContent)))) -> value v_response { - tc_ac.stop; - setverdict(pass, __SCOPE__ & ": Accepted updation for resource type remoteCSE containing attribute " & p_attribute[0]); - f_setResource(v_request.primitiveContent,int16); - } - [] mccPort.receive(mw_response(mw_responsePrimitiveOK(f_getTemplateFromPrimitiveContent(v_request.primitiveContent)))) -> value v_response { - tc_ac.stop; - setverdict(fail, __SCOPE__ & ": Wrong response status code in the response"); - f_setResource(v_request.primitiveContent,int16); - } - [] mccPort.receive(mw_response(mw_responsePrimitiveOK)) -> value v_response { + [] mccPortIn.receive(mw_request(v_request)) { tc_ac.stop; - setverdict(fail, __SCOPE__ & ": Accepted updation for resource type remoteCSE without containing attribute " & p_attribute[0]); + setverdict(pass, __SCOPE__ & ": Received request for updation for resource type remoteCSE containing attribute " & p_attribute[0]); f_setResource(v_request.primitiveContent,int16); } - [] mccPort.receive(mw_response(mw_responsePrimitiveKO)) -> value v_response { + [] mccPortIn.receive { tc_ac.stop; - setverdict(fail, __SCOPE__ & ": Rejected updation of resource type remoteCSE containing attribute" & p_attribute[0]); + setverdict(fail, __SCOPE__ & ": Error: Did not receive update request for resource type remoteCSE"); } [] tc_ac.timeout { setverdict(fail, __SCOPE__ & ": No answer while updating resource type remoteCSE");