Commit 9ab71263 authored by pintar's avatar pintar
Browse files

TIP_U01_03 and TIP_U01_04

parent 85f24061
Loading
Loading
Loading
Loading
+200 −30
Original line number Diff line number Diff line
@@ -43,20 +43,191 @@ module SS_Ims_TCFunctions {

	group SS_TIPTIR_SIPSIP{

		group Term_P_CSCF{
		}// end group Term_P_CSCF
        group TermUserE{
				
			function f_Sip_TIP_U01_003_PCSCF(in CSeq p_cSeq_s) runs on ImsComponent {

				var template Response v_Response;

				// Request-Uri refers to home network (SUT)
				// UE1 registers its public sip-url in home network (SUT)
				// UE contact is in home network (SUT)
				// UE authorizaton data is in home network (SUT)
				f_IMS_preamble_woRegistration(c_userProfile_PCSCFwithHomeUE, p_cSeq_s); // LibSip

				f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict());
				// Testbody

				// 	INVITE to UE1@IMS
				LibIms_Steps.f_setHeadersINVITE(vc_cSeq, c_userProfile_UE1atSUThome);
				f_SendINVITE(m_INVITE_Request_IMS(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via, vc_contact, omit, vc_route, vc_recordRoute, omit, omit, m_MBody_SDP(vc_sdp_local)));

				select (PX_TC_VA){ // PIXIT for TC VARIANT - awaiting 18x or 200
					case (1) {
						// 180  Ringing
						// add check if right PAssertedID is present
						v_Response := mw_Response_PAsserted_Privacy(c_statusLine180, vc_callId, vc_cSeq, *, m_Privacy(c_privacy_id));
						f_awaitingResponse(v_Response);
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
						f_awaitingResponse(mw_Response_Base(c_statusLine200,vc_callId, vc_cSeq)); 
						f_SendACK(m_ACK_Request_Base(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via));
					} 
					case (2) {	
						// 183 Session in Progress
						// add check if right PAssertedID is present
						v_Response := mw_Response_PAsserted_Privacy(c_statusLine183, vc_callId, vc_cSeq, *, m_Privacy(c_privacy_id));
						f_awaitingResponse(v_Response);
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
						f_awaitingResponse(mw_Response_Base(c_statusLine200, vc_callId, vc_cSeq)); 
						f_SendACK(m_ACK_Request_Base(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via));
					}
					case else {
						// 200 OK
						// add check if right PAssertedID is present
						v_Response := mw_Response_PAsserted_Privacy(c_statusLine200, vc_callId, vc_cSeq, *,m_Privacy(c_privacy_id));
						f_awaitingResponse(v_Response);
						f_SendACK(m_ACK_Request_Base(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via));
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
					}
				}		

				f_check_Conversation();

				f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict());

				//Send BYE and awaiting response
				f_terminateCall_IMS(vc_requestUri, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To);

				f_SIP_postamble_UE1_withoutRegistration();
			}// end f_Sip_TIP_U01_003_PCSCF
				
			function f_Sip_TIP_U01_004_PCSCF(in CSeq p_cSeq_s) runs on ImsComponent {

				var template Response v_Response;

				// Request-Uri refers to home network (SUT)
				// UE1 registers its public sip-url in home network (SUT)
				// UE contact is in home network (SUT)
				// UE authorizaton data is in home network (SUT)
				f_IMS_preamble_woRegistration(c_userProfile_PCSCFwithHomeUE, p_cSeq_s); // LibSip

				f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict());
				// Testbody

				// 	INVITE to UE1@IMS
				LibIms_Steps.f_setHeadersINVITE(vc_cSeq, c_userProfile_UE1atSUThome);
				f_SendINVITE(m_INVITE_Request_IMS(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via, vc_contact, omit, vc_route, vc_recordRoute, omit, omit, m_MBody_SDP(vc_sdp_local)));

				select (PX_TC_VA){ // PIXIT for TC VARIANT - awaiting 18x or 200
					case (1) {
						// 180  Ringing
						// add check if right PAssertedID is present
						v_Response := mw_Response_PAsserted_Privacy(c_statusLine180, vc_callId, vc_cSeq, *, m_Privacy(c_privacy_none));
						f_awaitingResponse(v_Response);
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
						f_awaitingResponse(mw_Response_Base(c_statusLine200,vc_callId, vc_cSeq)); 
						f_SendACK(m_ACK_Request_Base(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via));
					} 
					case (2) {	
						// 183 Session in Progress
						// add check if right PAssertedID is present
						v_Response := mw_Response_PAsserted_Privacy(c_statusLine183, vc_callId, vc_cSeq, *, m_Privacy(c_privacy_none));
						f_awaitingResponse(v_Response);
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
						f_awaitingResponse(mw_Response_Base(c_statusLine200, vc_callId, vc_cSeq)); 
						f_SendACK(m_ACK_Request_Base(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via));
					}
					case else {
						// 200 OK
						// add check if right PAssertedID is present
						v_Response := mw_Response_PAsserted_Privacy(c_statusLine200, vc_callId, vc_cSeq, *,m_Privacy(c_privacy_none));
						f_awaitingResponse(v_Response);
						f_SendACK(m_ACK_Request_Base(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via));
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
					}
				}		

				f_check_Conversation();

				f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict());

				//Send BYE and awaiting response
				f_terminateCall_IMS(vc_requestUri, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To);

				f_SIP_postamble_UE1_withoutRegistration();
			}// end f_Sip_TIP_U01_004_PCSCF
			
        }// end group TermUserE
		group OrigUserE{
				
			function f_Sip_TIP_U02_001_PCSCF(in CSeq p_cSeq_s) runs on ImsComponent {

				var template PAssertedID v_PAsserted;

				// set PAssertedID
				v_PAsserted := m_PAssertedID(m_AddrUnion_NameAddr(PX_SIP_NameAddr_PAsserted));

				// IMS1  interface profile initialization
				f_init_interfaceprofile(c_interfaceProfile_IMS_SUT_PCSCF1);

				// IMS1UE1 contact is in home network (TS)
				f_IMS_preamble_woRegistration(c_userProfile_UE1atSUThome, p_cSeq_s); // configuration of local user IMS1UE1
		
				// Note: UE1 is registerd in SUT only, but not registered in IMS1
				f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict());

				// Testbody
		
				f_awaitingINVITE(mw_INVITE_Request_Base);

				select(PX_TC_VA){ // PIXIT for TC VARIANT
					case (1) {
						// 180  Ringing
						//f_SendResponse_with_ID_params(StatusLine180,omit,v_PAsserted,omit);
						//IUT (P-CSCF) should set&send PAssertedID parameter to originating side
						f_sendResponse(m_Response_PAsserted_Privacy(c_statusLine180, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To, vc_via, v_PAsserted, omit));
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
						f_sendResponse(m_Response_mbody(c_statusLine200, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To, vc_via, valueof( m_MBody_SDP(vc_sdp_local))));
						f_awaitingACK(mw_ACK_Request_Base(vc_callId));
					} 
					case (2) {
						// 183 Session in Progress
						//f_SendResponse_with_ID_params(StatusLine183,omit,v_PAsserted,omit);		
						//IUT (P-CSCF) should set&send PAssertedID parameter to originating side
						f_sendResponse(m_Response_PAsserted_Privacy(c_statusLine183, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To, vc_via, v_PAsserted, omit));
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
						f_sendResponse(m_Response_mbody(c_statusLine200, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To, vc_via, valueof( m_MBody_SDP(vc_sdp_local))));
						f_awaitingACK(mw_ACK_Request_Base(vc_callId));							
					} 
					case else {
						// 200 OK
						//f_SendResponse_with_ID_params(StatusLine200,omit,v_PAsserted,omit);		
						//IUT (P-CSCF) should set&send PAssertedID parameter to originating side
						f_sendResponse(m_Response_PAsserted_Privacy_mbody(c_statusLine200, vc_callId, vc_cSeq, vc_caller_From, vc_caller_To, vc_via, v_PAsserted, omit, valueof( m_MBody_SDP(vc_sdp_local))));
						f_awaitingACK(mw_ACK_Request_Base(vc_callId));
						f_selfOrClientSyncAndVerdict(c_sync1, f_getVerdict());
					}		
				}
					
				f_check_Conversation();

				f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict());// sync point test body done
				
				//await BYE and send 200 OK
				f_awaitingBYE_sendReply(mw_BYE_Request_Base(vc_callId));

				// UE1 is registerd in SUT only, but not registered in IMS1
				f_SIP_postamble_IMS1_withoutRegistration();

			}// end f_Sip_TIP_U02_001_PCSCF
			
		}// end group OrigUserE
		group DestNetw{
		}// end group DestNetw
		group TIR{
		}// end group TIR
		group DestAS{
		}// end group DestAS
		group OrigAS{
		}// end group OrigAS
		group CDIV{
		}// end group CDIV
		group OrigNetw{
		}// end group OrigNetw
		group OtherNetw{
				
			function f_Sip_TIP_N04_001_Ic(in CSeq p_cSeq_s) runs on ImsComponent {
@@ -532,20 +703,31 @@ group SuplementaryService_CUG{
		group Originating_UE{
		}// end group Originating_UE
		group Originating_AS{
			
			function f_Sip_CUG_N01_001_AS1(in CSeq p_cSeq_s) runs on ImsComponent {
				
				// Request-Uri refers to home network (SUT)
				// UE1 registers its public sip-url in home network (SUT)
				// UE contact is in home network (SUT)
				// UE authorizaton data is in home network (SUT)
				f_IMS_preamble_woRegistration(c_userProfile_SCSCFwithHomeUE, p_cSeq_s); // LibSip

				f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict());
				// Testbody

				// 	INVITE to AS1@IMS
				vc_xml_local := valueof(m_XmlBody_CUG(m_CUG(omit, omit, omit, omit)));
				LibIms_Steps.f_setHeadersINVITE(vc_cSeq, c_userProfile_AS1);
				f_SendINVITE(m_INVITE_Request_Mime_IMS(vc_requestUri, vc_callId, vc_cSeq, vc_from, vc_to, vc_via, vc_contact, omit, vc_route, vc_recordRoute, omit, omit, m_MBody_MIMESdpXml(vc_sdp_local, vc_xml_local)));
				
			} // end f_Sip_CUG_N01_001_AS1
			
		}// end group Originating_AS
		group Terminating_AS{
		}// end group Terminating_AS
		group Interaction{
		}// end group Interaction
		
	}// end group SS_CUG_SIPSIP
	
	group SS_CUG_SIPISUP{
	}// end group SS_CUG_SIPISUP
	
	group SS_CUG_ISUPSIP{
	}// end group SS_CUG_ISUPSIP
	
}// end  group SuplementaryService_CUG 
  
group SuplementaryService_ACR{
@@ -565,12 +747,6 @@ group SuplementaryService_ACR{
		
	}// end group SS_ACR_SIPSIP
	
	group SS_ACR_SIPISUP{
	}// end group SS_ACR_SIPISUP
	
	group SS_ACR_ISUPSIP{
	}// end group SS_ACR_ISUPSIP
	
}// end  group SuplementaryService_ACR 
  
group SuplementaryService_MCID{
@@ -585,12 +761,6 @@ group SuplementaryService_MCID{
		}// end group destination_UE
		
	}// end group SS_MCID_SIPSIP
	
	group SS_MCID_SIPISUP{
	}// end group SS_MCID_SIPISUP
	
	group SS_MCID_ISUPSIP{
	}// end group SS_MCID_ISUPSIP
}// end  group SuplementaryService_MCID 

} // end module SipIsup_SIP_TCFunctions