Loading LibGtpv2C_Configuration.ttcn +30 −6 Original line number Diff line number Diff line Loading @@ -173,11 +173,18 @@ module LibGtpv2C_Configuration { */ group tlviVariableLengthCalculations { // function f_calculateInformationElementLength_cause(in Cause p_cause) return Cause { // p_cause.length_ := sizeof(p_cause); // // return p_cause; // } // End of function f_calculateInformationElementLength_cause /** * @desc Update length filed according to the content * @see ETSI TS 129 274 V9.13.0 Clause 8.28 Bearer Context * @see ETSI TS 129 274 V9.13.0 Table 8.28-1: Bearer Context Grouped Type */ function f_calculateInformationElementLength_bearerContext( in template (value) BearerContext p_bearer_context ) return BearerContext { p_bearer_context.length_ := sizeof(p_bearer_context) - 4/*Size of IE mandatory fields*/; // FIXME To be reviewed return p_bearer_context; } // End of function f_calculateInformationElementLength_bearerContext } // End of group tlviVariableLengthCalculations Loading @@ -203,6 +210,23 @@ module LibGtpv2C_Configuration { return vc_restartCounter; } // End of function f_getNextRestartCounter group extractInformationElementFunctions { function f_extract_teid(in Gtpv2Pdu p_gtpv2Pdu) return Oct4 { // Sanity check if (not(ispresent(p_gtpv2Pdu.extHeader.teid))) { return '00000000'O; } return p_gtpv2Pdu.extHeader.teid; } function f_extract_sequenceNumber(in Gtpv2Pdu p_gtpv2Pdu) return UInt24 { return p_gtpv2Pdu.extHeader.sequenceNumber; } } // End of group extractInformationElementFunctions } // End of group helperFunctions } // End of module LibGtpv2C_Configuration No newline at end of file LibGtpv2C_MME_Functions.ttcn +20 −12 Original line number Diff line number Diff line Loading @@ -46,7 +46,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoRequest ), -, Loading @@ -61,7 +61,7 @@ module LibGtpv2C_MME_Functions { gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_echoResponse), m_header_noteid(e_echoResponse), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoResponse( m_gtpv2EchoResponse( Loading Loading @@ -109,7 +109,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoRequest ), -, Loading @@ -124,7 +124,7 @@ module LibGtpv2C_MME_Functions { gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_echoResponse), m_header_noteid(e_echoResponse), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoResponse( m_gtpv2EchoResponse( Loading Loading @@ -176,7 +176,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_invalid_version mw_header_invalid_version ) ) ) { Loading @@ -185,7 +185,7 @@ module LibGtpv2C_MME_Functions { gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_versionNotSupported), m_header_noteid(e_versionNotSupported), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoResponse( m_gtpv2EchoResponse( Loading Loading @@ -230,10 +230,11 @@ module LibGtpv2C_MME_Functions { function f_TC_S11_MME_TM_01() runs on Gtpv2CComponent { // Local variables var Gtpv2Ind v_gtpv2Ind; // Preamble f_preamble_MME(); // Nothing to do, Echo Request is a periodic message // Nothing to do, see f_TC_S1_MME_TM_01 f_selfOrClientSyncAndVerdict(c_prDone, e_success); log("*** " & __SCOPE__ & ": INFO: Preamble done. ***"); Loading @@ -244,7 +245,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_teid( e_createSessionRequest ), -, Loading @@ -253,16 +254,23 @@ module LibGtpv2C_MME_Functions { ) ) ) ) { ) -> value v_gtpv2Ind { tc_ac.stop; // Send echo reply gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_createSessionResponse), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_header_noteid(e_createSessionResponse), m_gtpv2ExtendedHeader_teid( f_extract_teid(v_gtpv2Ind.msgIn), f_extract_sequenceNumber(v_gtpv2Ind.msgIn) ), m_gtpv2Payload_createSessionResponse( m_gtpv2createSessionResponse( m_gtpv2CreateSessionResponse_dummy( m_cause(16), // FIXME Crete constance See 3GPP TS 29.274 version 9.11.0 Release 9 Table 8.4-1: Cause values f_calculateInformationElementLength_bearerContext( m_BearerContexts_dummy // FIXME Create template m_BearerContextsCreated ) ) ) ) Loading LibGtpv2C_Pixits.ttcn +87 −0 Original line number Diff line number Diff line /** * @author ETSI/STF498 * @version $Url$ * $Id$ * @dec Pixits module for INT GTPv2-C library * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) */ module LibGtpv2C_Pixits { // Libcommon Loading @@ -6,10 +13,90 @@ module LibGtpv2C_Pixits { // LibGtpv2C import from LibGtpv2C_TypesAndValues all; /** * @desc IP address of the test system acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/1 */ modulepar charstring PX_GTPC_S11_ETS_MME_IPADDR := "127.0.0.1"; /** * @desc Port number of the test system acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/2 */ modulepar charstring PX_GTPC_S11_ETS_MME_PORT := "12345"; /** * @desc IP address of the test system acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/3 */ modulepar charstring PX_GTPC_S11_ETS_SGW_IPADDR := "127.0.0.1"; /** * @desc Port number of the test system acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/4 */ modulepar charstring PX_GTPC_S11_ETS_SGW_PORT := "12346"; /** * @desc IP address of the system under test acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/5 */ modulepar charstring PX_GTPC_S11_SUT_MME_IPADDR := "127.0.0.1"; /** * @desc Port number of the system under test acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/6 */ modulepar charstring PX_GTPC_S11_SUT_MME_PORT := "12347"; /** * @desc IP address of the system under test acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/7 */ modulepar charstring PX_GTPC_S11_SUT_SGW_IPADDR := "127.0.0.1"; /** * @desc Port number of the system under test acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/8 */ modulepar charstring PX_GTPC_S11_SUT_SGW_PORT := "12348"; modulepar charstring PX_CALLER_IMSI := "33614000000001"; modulepar charstring PX_CALLER_MSISDN := "337000000001"; modulepar charstring PX_CALLER_MEI := "99990000000100"; modulepar charstring PX_CALLEE_IMSI := "220614000000002"; modulepar charstring PX_CALLEE_MSISDN := "337000000002"; modulepar charstring PX_CALLEE_MEI := "99990000000200"; /** * @desc MAC address of the system under test acting as MME */ modulepar MacAddress PX_MME_MAC_ADDRESS := '000000000000'O; /** * @desc MAC address of the system under test acting as S-GW */ modulepar MacAddress PX_SGW_MAC_ADDRESS := '000000000000'O; /** * @desc */ modulepar UInt3 PX_WRONG_PROTOCOL_VERSION := 0; } // End of module LibGtpv2C_Pixits No newline at end of file LibGtpv2C_SGW_Functions.ttcn +77 −24 Original line number Diff line number Diff line Loading @@ -17,24 +17,7 @@ module LibGtpv2C_SGW_Functions { import from LibGtpv2C_TestSystem all; import from LibGtpv2C_Pics all; import from LibGtpv2C_Configuration all; import from LibGtpv2C_Templates { template m_gtpv2ExtendedHeader_noteid, m_gtpv2EchoRequest, m_gtpv2Payload_echoRequest, m_gtpv2Pdu, m_gtpv2Req_SGW, m_mheader_noteid, m_mheader_noteid_invalid_version, m_negative_cause, m_recovery, m_recovery_invalid, mw_gtpv2EchoResponse, mw_gtpv2Ind, mw_gtpv2Payload_echoResponse, mw_gtpv2Pdu, mw_mheader_noteid; } import from LibGtpv2C_Templates all; /** * @desc This group contains all test case for IUT acting as a SGW Loading @@ -55,7 +38,7 @@ module LibGtpv2C_SGW_Functions { gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_mheader_noteid(e_echoRequest), m_header_noteid(e_echoRequest), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoRequest( m_gtpv2EchoRequest( Loading @@ -76,7 +59,7 @@ module LibGtpv2C_SGW_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoResponse ), -, Loading Loading @@ -114,7 +97,7 @@ module LibGtpv2C_SGW_Functions { gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_mheader_noteid(e_echoRequest), m_header_noteid(e_echoRequest), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoRequest( m_gtpv2EchoRequest( Loading @@ -135,7 +118,7 @@ module LibGtpv2C_SGW_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoResponse ), -, Loading Loading @@ -180,7 +163,7 @@ module LibGtpv2C_SGW_Functions { gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_mheader_noteid_invalid_version(e_echoRequest), m_header_noteid_invalid_version(e_echoRequest), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoRequest( m_gtpv2EchoRequest( Loading @@ -201,7 +184,7 @@ module LibGtpv2C_SGW_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_versionNotSupported ), -, Loading Loading @@ -241,6 +224,76 @@ module LibGtpv2C_SGW_Functions { */ group tunnelManagement { /** * @desc Validate the Create Session Request/Response and the Modify Bearer Request/Response Procedure between MME and S-GW as part of the ATTACH Procedure - MME role * @verdict pass on success, inconc on timeout, fail otherwise */ function f_TC_S11_SGW_TM_01() runs on Gtpv2CComponent { // Local variables // Preamble f_preamble_SGW(); gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_header_noteid(e_createSessionRequest), m_gtpv2ExtendedHeader_teid( '00000000'O, // FIXME Use a PIXIT f_getNextSequenceNumber() ), m_gtpv2Payload_createSessionRequest( m_gtpv2CreateSessionRequest_dummy( // FIXME To be continued ) ) ) ) ); f_selfOrClientSyncAndVerdict(c_prDone, e_success); log("*** " & __SCOPE__ & ": INFO: Preamble done. ***"); // Test Body tc_ac.start; // 1. Verify that the MME sends Create Session Request and receives the Create Session Response alt { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_header_teid( e_createSessionResponse ), -, mw_gtpv2Payload_createSessionResponse( mw_gtpv2CreateSessionResponse_dummy // FIXME To be refined ) ) ) ) { tc_ac.stop; // Send echo reply log("*** " & testcasename() & ": PASS: Successful Echo Request Procedure ***"); f_selfOrClientSyncAndVerdict(c_tbDone, e_success); } [] tc_ac.timeout { log("*** " & testcasename() & ": INCONC: Expected message not received ***"); f_selfOrClientSyncAndVerdict(c_tbDone, e_timeout); } } // End of 'alt' statement // 2. Verify that the MME sends Modify Bearer Request and receives the Modify Bearer Response // TODO // TODO If S1-MME used, need synchronisation point to trigger Initial Context Setup Response and Attach Commplete messages // Postamble f_postamble_SGW(); f_selfOrClientSyncAndVerdict(c_poDone, e_success); log("*** " & __SCOPE__ & ": INFO: Postamble done. ***"); } // End of function f_TC_S11_SGW_TM_01 } // End of group tunnelManagement Loading LibGtpv2C_Templates.ttcn +446 −116 File changed.Preview size limit exceeded, changes collapsed. Show changes Loading
LibGtpv2C_Configuration.ttcn +30 −6 Original line number Diff line number Diff line Loading @@ -173,11 +173,18 @@ module LibGtpv2C_Configuration { */ group tlviVariableLengthCalculations { // function f_calculateInformationElementLength_cause(in Cause p_cause) return Cause { // p_cause.length_ := sizeof(p_cause); // // return p_cause; // } // End of function f_calculateInformationElementLength_cause /** * @desc Update length filed according to the content * @see ETSI TS 129 274 V9.13.0 Clause 8.28 Bearer Context * @see ETSI TS 129 274 V9.13.0 Table 8.28-1: Bearer Context Grouped Type */ function f_calculateInformationElementLength_bearerContext( in template (value) BearerContext p_bearer_context ) return BearerContext { p_bearer_context.length_ := sizeof(p_bearer_context) - 4/*Size of IE mandatory fields*/; // FIXME To be reviewed return p_bearer_context; } // End of function f_calculateInformationElementLength_bearerContext } // End of group tlviVariableLengthCalculations Loading @@ -203,6 +210,23 @@ module LibGtpv2C_Configuration { return vc_restartCounter; } // End of function f_getNextRestartCounter group extractInformationElementFunctions { function f_extract_teid(in Gtpv2Pdu p_gtpv2Pdu) return Oct4 { // Sanity check if (not(ispresent(p_gtpv2Pdu.extHeader.teid))) { return '00000000'O; } return p_gtpv2Pdu.extHeader.teid; } function f_extract_sequenceNumber(in Gtpv2Pdu p_gtpv2Pdu) return UInt24 { return p_gtpv2Pdu.extHeader.sequenceNumber; } } // End of group extractInformationElementFunctions } // End of group helperFunctions } // End of module LibGtpv2C_Configuration No newline at end of file
LibGtpv2C_MME_Functions.ttcn +20 −12 Original line number Diff line number Diff line Loading @@ -46,7 +46,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoRequest ), -, Loading @@ -61,7 +61,7 @@ module LibGtpv2C_MME_Functions { gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_echoResponse), m_header_noteid(e_echoResponse), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoResponse( m_gtpv2EchoResponse( Loading Loading @@ -109,7 +109,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoRequest ), -, Loading @@ -124,7 +124,7 @@ module LibGtpv2C_MME_Functions { gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_echoResponse), m_header_noteid(e_echoResponse), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoResponse( m_gtpv2EchoResponse( Loading Loading @@ -176,7 +176,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_invalid_version mw_header_invalid_version ) ) ) { Loading @@ -185,7 +185,7 @@ module LibGtpv2C_MME_Functions { gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_versionNotSupported), m_header_noteid(e_versionNotSupported), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoResponse( m_gtpv2EchoResponse( Loading Loading @@ -230,10 +230,11 @@ module LibGtpv2C_MME_Functions { function f_TC_S11_MME_TM_01() runs on Gtpv2CComponent { // Local variables var Gtpv2Ind v_gtpv2Ind; // Preamble f_preamble_MME(); // Nothing to do, Echo Request is a periodic message // Nothing to do, see f_TC_S1_MME_TM_01 f_selfOrClientSyncAndVerdict(c_prDone, e_success); log("*** " & __SCOPE__ & ": INFO: Preamble done. ***"); Loading @@ -244,7 +245,7 @@ module LibGtpv2C_MME_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_teid( e_createSessionRequest ), -, Loading @@ -253,16 +254,23 @@ module LibGtpv2C_MME_Functions { ) ) ) ) { ) -> value v_gtpv2Ind { tc_ac.stop; // Send echo reply gtpv2CPort.send( m_gtpv2Req_MME( m_gtpv2Pdu( m_mheader_noteid(e_createSessionResponse), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_header_noteid(e_createSessionResponse), m_gtpv2ExtendedHeader_teid( f_extract_teid(v_gtpv2Ind.msgIn), f_extract_sequenceNumber(v_gtpv2Ind.msgIn) ), m_gtpv2Payload_createSessionResponse( m_gtpv2createSessionResponse( m_gtpv2CreateSessionResponse_dummy( m_cause(16), // FIXME Crete constance See 3GPP TS 29.274 version 9.11.0 Release 9 Table 8.4-1: Cause values f_calculateInformationElementLength_bearerContext( m_BearerContexts_dummy // FIXME Create template m_BearerContextsCreated ) ) ) ) Loading
LibGtpv2C_Pixits.ttcn +87 −0 Original line number Diff line number Diff line /** * @author ETSI/STF498 * @version $Url$ * $Id$ * @dec Pixits module for INT GTPv2-C library * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) */ module LibGtpv2C_Pixits { // Libcommon Loading @@ -6,10 +13,90 @@ module LibGtpv2C_Pixits { // LibGtpv2C import from LibGtpv2C_TypesAndValues all; /** * @desc IP address of the test system acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/1 */ modulepar charstring PX_GTPC_S11_ETS_MME_IPADDR := "127.0.0.1"; /** * @desc Port number of the test system acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/2 */ modulepar charstring PX_GTPC_S11_ETS_MME_PORT := "12345"; /** * @desc IP address of the test system acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/3 */ modulepar charstring PX_GTPC_S11_ETS_SGW_IPADDR := "127.0.0.1"; /** * @desc Port number of the test system acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/4 */ modulepar charstring PX_GTPC_S11_ETS_SGW_PORT := "12346"; /** * @desc IP address of the system under test acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/5 */ modulepar charstring PX_GTPC_S11_SUT_MME_IPADDR := "127.0.0.1"; /** * @desc Port number of the system under test acting as MME * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/6 */ modulepar charstring PX_GTPC_S11_SUT_MME_PORT := "12347"; /** * @desc IP address of the system under test acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/7 */ modulepar charstring PX_GTPC_S11_SUT_SGW_IPADDR := "127.0.0.1"; /** * @desc Port number of the system under test acting as S-GW * @see ETSI TS 103 202-3 V0.0.1 2 (2015-06) Table A.7/8 */ modulepar charstring PX_GTPC_S11_SUT_SGW_PORT := "12348"; modulepar charstring PX_CALLER_IMSI := "33614000000001"; modulepar charstring PX_CALLER_MSISDN := "337000000001"; modulepar charstring PX_CALLER_MEI := "99990000000100"; modulepar charstring PX_CALLEE_IMSI := "220614000000002"; modulepar charstring PX_CALLEE_MSISDN := "337000000002"; modulepar charstring PX_CALLEE_MEI := "99990000000200"; /** * @desc MAC address of the system under test acting as MME */ modulepar MacAddress PX_MME_MAC_ADDRESS := '000000000000'O; /** * @desc MAC address of the system under test acting as S-GW */ modulepar MacAddress PX_SGW_MAC_ADDRESS := '000000000000'O; /** * @desc */ modulepar UInt3 PX_WRONG_PROTOCOL_VERSION := 0; } // End of module LibGtpv2C_Pixits No newline at end of file
LibGtpv2C_SGW_Functions.ttcn +77 −24 Original line number Diff line number Diff line Loading @@ -17,24 +17,7 @@ module LibGtpv2C_SGW_Functions { import from LibGtpv2C_TestSystem all; import from LibGtpv2C_Pics all; import from LibGtpv2C_Configuration all; import from LibGtpv2C_Templates { template m_gtpv2ExtendedHeader_noteid, m_gtpv2EchoRequest, m_gtpv2Payload_echoRequest, m_gtpv2Pdu, m_gtpv2Req_SGW, m_mheader_noteid, m_mheader_noteid_invalid_version, m_negative_cause, m_recovery, m_recovery_invalid, mw_gtpv2EchoResponse, mw_gtpv2Ind, mw_gtpv2Payload_echoResponse, mw_gtpv2Pdu, mw_mheader_noteid; } import from LibGtpv2C_Templates all; /** * @desc This group contains all test case for IUT acting as a SGW Loading @@ -55,7 +38,7 @@ module LibGtpv2C_SGW_Functions { gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_mheader_noteid(e_echoRequest), m_header_noteid(e_echoRequest), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoRequest( m_gtpv2EchoRequest( Loading @@ -76,7 +59,7 @@ module LibGtpv2C_SGW_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoResponse ), -, Loading Loading @@ -114,7 +97,7 @@ module LibGtpv2C_SGW_Functions { gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_mheader_noteid(e_echoRequest), m_header_noteid(e_echoRequest), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoRequest( m_gtpv2EchoRequest( Loading @@ -135,7 +118,7 @@ module LibGtpv2C_SGW_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_echoResponse ), -, Loading Loading @@ -180,7 +163,7 @@ module LibGtpv2C_SGW_Functions { gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_mheader_noteid_invalid_version(e_echoRequest), m_header_noteid_invalid_version(e_echoRequest), m_gtpv2ExtendedHeader_noteid(f_getNextSequenceNumber()), m_gtpv2Payload_echoRequest( m_gtpv2EchoRequest( Loading @@ -201,7 +184,7 @@ module LibGtpv2C_SGW_Functions { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_mheader_noteid( mw_header_noteid( e_versionNotSupported ), -, Loading Loading @@ -241,6 +224,76 @@ module LibGtpv2C_SGW_Functions { */ group tunnelManagement { /** * @desc Validate the Create Session Request/Response and the Modify Bearer Request/Response Procedure between MME and S-GW as part of the ATTACH Procedure - MME role * @verdict pass on success, inconc on timeout, fail otherwise */ function f_TC_S11_SGW_TM_01() runs on Gtpv2CComponent { // Local variables // Preamble f_preamble_SGW(); gtpv2CPort.send( m_gtpv2Req_SGW( m_gtpv2Pdu( m_header_noteid(e_createSessionRequest), m_gtpv2ExtendedHeader_teid( '00000000'O, // FIXME Use a PIXIT f_getNextSequenceNumber() ), m_gtpv2Payload_createSessionRequest( m_gtpv2CreateSessionRequest_dummy( // FIXME To be continued ) ) ) ) ); f_selfOrClientSyncAndVerdict(c_prDone, e_success); log("*** " & __SCOPE__ & ": INFO: Preamble done. ***"); // Test Body tc_ac.start; // 1. Verify that the MME sends Create Session Request and receives the Create Session Response alt { [] gtpv2CPort.receive( mw_gtpv2Ind( mw_gtpv2Pdu( mw_header_teid( e_createSessionResponse ), -, mw_gtpv2Payload_createSessionResponse( mw_gtpv2CreateSessionResponse_dummy // FIXME To be refined ) ) ) ) { tc_ac.stop; // Send echo reply log("*** " & testcasename() & ": PASS: Successful Echo Request Procedure ***"); f_selfOrClientSyncAndVerdict(c_tbDone, e_success); } [] tc_ac.timeout { log("*** " & testcasename() & ": INCONC: Expected message not received ***"); f_selfOrClientSyncAndVerdict(c_tbDone, e_timeout); } } // End of 'alt' statement // 2. Verify that the MME sends Modify Bearer Request and receives the Modify Bearer Response // TODO // TODO If S1-MME used, need synchronisation point to trigger Initial Context Setup Response and Attach Commplete messages // Postamble f_postamble_SGW(); f_selfOrClientSyncAndVerdict(c_poDone, e_success); log("*** " & __SCOPE__ & ": INFO: Postamble done. ***"); } // End of function f_TC_S11_SGW_TM_01 } // End of group tunnelManagement Loading
LibGtpv2C_Templates.ttcn +446 −116 File changed.Preview size limit exceeded, changes collapsed. Show changes