Commit 7c3ef5ad authored by pintar's avatar pintar
Browse files

MME_HAS_04-16 tests and related templates added

parent 353c8fbe
Loading
Loading
Loading
Loading
+40 −0
Original line number Original line Diff line number Diff line
@@ -242,6 +242,27 @@ module LibS1AP_Steps {
            f_recv_S1AP_initiatingMessage(mw_HandoverCancel(p_value))
            f_recv_S1AP_initiatingMessage(mw_HandoverCancel(p_value))
        } // End of function f_recv_HandoverCancel
        } // End of function f_recv_HandoverCancel
       
       
        /**
         * @desc Receive S1AP Message Handover CancelAcknowledge
         * @param p_value Receive template for Handover Cancel Acknowledge IEs
         */
        function f_recv_HandoverCancelAck(in template (present) RecordOf_ProtocolIE p_value :=?
        ) runs on S1APComponent {
            f_recv_S1AP_successfulOutcome(mw_HandoverCancelAck(p_value))
        } // End of function f_recv_HandoverCancelAck
        
        /**
         * @desc Receive S1AP Message MME STATUS TRANSFER
         * @param p_value Receive template for MME_STATUS_TRANSFER IEs
         * @see ETSI TS 136 413 V13.4.0 Clause 9.1.5.14 MME STATUS TRANSFER
         */
        function f_recv_Mme_Status_Transfer(
                                                   template (present) RecordOf_ProtocolIE p_value := ?
        ) runs on S1APComponent {
            f_recv_S1AP_initiatingMessage(mw_Mme_Status_Transfer(p_value))
        } // End of f_recv_Mme_Status_Transfer
        
        
        /**
        /**
         * @desc Receive S1AP Message Handover Notify
         * @desc Receive S1AP Message Handover Notify
         * @param p_value Receive template for Handover Notify IEs
         * @param p_value Receive template for Handover Notify IEs
@@ -1114,6 +1135,15 @@ module LibS1AP_Steps {
            f_send_S1AP_initiatingMessage(m_HandoverRequest(p_value))
            f_send_S1AP_initiatingMessage(m_HandoverRequest(p_value))
        } // End of function f_send_HandoverRequest
        } // End of function f_send_HandoverRequest
        
        
        /**
         * @desc Send S1AP Message f_send_HandoverCancel
         * @param p_value Send template with IE for HandoverCancel
         */
        function f_send_HandoverCancel(in template (value) RecordOf_ProtocolIE p_value
        ) runs on S1APComponent {
            f_send_S1AP_initiatingMessage(m_HandoverCancel(p_value))
        } // End of function f_send_HandoverCancel
        
        /**
        /**
         * @desc Send S1AP Message Handover Cancel Acknowledge
         * @desc Send S1AP Message Handover Cancel Acknowledge
         * @param p_value Send template with IE for Handover Cancel Acknowledge
         * @param p_value Send template with IE for Handover Cancel Acknowledge
@@ -1124,6 +1154,16 @@ module LibS1AP_Steps {
            f_send_S1AP_successfulOutcome(m_HandoverCancelAck(p_value))
            f_send_S1AP_successfulOutcome(m_HandoverCancelAck(p_value))
        } // End of function f_send_HandoverCancelAcknowledge
        } // End of function f_send_HandoverCancelAcknowledge


        /**
         * @desc Send S1AP Message ENB STATUS TRANSFER
         * @param p_value Send template with IE for ENB STATUS TRANSFER 
         */
        function f_send_eNB_Status_Transfer(
                                                 in template (value) RecordOf_ProtocolIE p_value
        ) runs on S1APComponent {
            f_send_S1AP_initiatingMessage(m_eNB_Status_Transfer(p_value))
        } // End of function f_send_eNB_Status_Transfer
        
        /**
        /**
         * @desc Send S1AP Message Handover Command
         * @desc Send S1AP Message Handover Command
         * @param p_value Send template with IE for Handover Command
         * @param p_value Send template with IE for Handover Command
+142 −2
Original line number Original line Diff line number Diff line
@@ -233,7 +233,28 @@ module LibS1AP_Templates {
                group HandoverCancelation{
                group HandoverCancelation{


                    /**
                    /**
                     * @desc Receive template for SuccessfulOutcome message with Handover Cancel Acknowledge payload
                     * @desc Send template for InitiatingMessage message with Handover Cancel payload
                     * @param p_value           The protocol information elements.
                     */
                    template (value) InitiatingMessage m_HandoverCancel(
                                                                           template (value) RecordOf_ProtocolIE p_value) := {
                        procedureCode := id_HandoverCancel,
                        criticality := reject,
                        value_ := {RecordOf_ProtocolIE := p_value}
                    } // End of template m_HandoverCancel
                    
                    template (value) RecordOf_ProtocolIE m_HandoverCancelIEs(
                        in template (value) MME_UE_S1AP_ID p_MME_value,
                        in template (value) ENB_UE_S1AP_ID p_eNB_value,
                        in template (value) Cause p_cause_value
                       ) := {
                            m_MME_UE_S1AP_ID(p_MME_value),
                            m_eNB_UE_S1AP_ID(p_eNB_value),
                            m_cause_IE(p_cause_value)
                       } // End of template m_HandoverCancelIEs
                       
                    /**
                     * @desc Send template for SuccessfulOutcome message with Handover Cancel Acknowledge payload
                     * @param p_value           The protocol information elements.
                     * @param p_value           The protocol information elements.
                     */
                     */
                    template (value) SuccessfulOutcome m_HandoverCancelAck(
                    template (value) SuccessfulOutcome m_HandoverCancelAck(
@@ -251,6 +272,27 @@ module LibS1AP_Templates {
                            m_eNB_UE_S1AP_ID(p_eNB_value)
                            m_eNB_UE_S1AP_ID(p_eNB_value)
                       } // End of template m_HandoverCancelAckIEs
                       } // End of template m_HandoverCancelAckIEs
                    
                    
                    /**
                     * @desc Send template for InitiatingMessage message with eNB_Status_Transfer payload
                     * @param p_value           The protocol information elements.
                     */
                    template (value) InitiatingMessage m_eNB_Status_Transfer(
                                                                           template (value) RecordOf_ProtocolIE p_value) := {
                        procedureCode := id_eNBStatusTransfer,
                        criticality := ignore,
                        value_ := {RecordOf_ProtocolIE := p_value}
                    } // End of template m_eNB_Status_Transfer

                    template (value) RecordOf_ProtocolIE m_eNB_Status_TransferIEs(
                        in template (value) MME_UE_S1AP_ID p_MME_value,
                        in template (value) ENB_UE_S1AP_ID p_eNB_value,
                        in template (value) ENB_StatusTransfer_TransparentContainer p_enb_stc_value
                       ) := {
                            m_MME_UE_S1AP_ID(p_MME_value),
                            m_eNB_UE_S1AP_ID(p_eNB_value),
                            m_eNBStatusTransferTransparentContainer_IE(p_enb_stc_value)
                       } // End of template m_eNB_Status_TransferIEs
                       
                }// End of group HandoverCancelation
                }// End of group HandoverCancelation
                
                
                group PathSwitchRequest_send {
                group PathSwitchRequest_send {
@@ -1306,6 +1348,47 @@ module LibS1AP_Templates {
                            mw_cause_IE(p_Cause_value)
                            mw_cause_IE(p_Cause_value)
                       } // End of template mw_HandoverCancelIEs
                       } // End of template mw_HandoverCancelIEs


                    /**
                     * @desc Receive template for SuccessfulOutcome message with Handover Cancel Acknowledge payload
                     * @param p_value           The expected protocol information elements. Default: ?
                     */
                    template (present) SuccessfulOutcome mw_HandoverCancelAck(
                                                                           template (present) RecordOf_ProtocolIE p_value) := {
                        procedureCode := id_HandoverCancel,
                        criticality := reject,
                        value_ := {RecordOf_ProtocolIE := p_value}
                    } // End of template mw_HandoverCancelAck
                    
                    template (present) RecordOf_ProtocolIE mw_HandoverCancelAckIEs(
                        template (present) MME_UE_S1AP_ID p_MME_value := ?,
                        template (present) ENB_UE_S1AP_ID p_eNB_value := ?
                       ) := {
                            mw_MME_UE_S1AP_ID(p_MME_value),
                            mw_eNB_UE_S1AP_ID(p_eNB_value)
                       } // End of template mw_HandoverCancelAckIEs
                         

                    /**
                     * @desc Receive template for InitiatingMessage message with Mme_Status_Transfer payload
                     * @param p_value           The expected protocol information elements. Default: ?
                     */
                    template (present) InitiatingMessage mw_Mme_Status_Transfer(
                                                                           template (present) RecordOf_ProtocolIE p_value) := {
                        procedureCode := id_MMEStatusTransfer,
                        criticality := reject,
                        value_ := {RecordOf_ProtocolIE := p_value}
                    } // End of template mw_HandoverCancel
                    
                    template (present) RecordOf_ProtocolIE mw_Mme_Status_TransferIEs(
                        template (present) MME_UE_S1AP_ID p_MME_value := ?,
                        template (present) ENB_UE_S1AP_ID p_eNB_value := ?,
                        template (present) ENB_StatusTransfer_TransparentContainer p_enb_stc_value := ?
                       ) := {
                            mw_MME_UE_S1AP_ID(p_MME_value),
                            mw_eNB_UE_S1AP_ID(p_eNB_value),
                            mw_eNBStatusTransferTransparentContainer_IE(p_enb_stc_value)
                       } // End of template mw_Mme_Status_TransferIEs    
                         
                }// End of group HandoverCancelation
                }// End of group HandoverCancelation
                    
                    
                group PathSwitchRequest{
                group PathSwitchRequest{
@@ -4005,6 +4088,63 @@ module LibS1AP_Templates {
                value_ := {NASSecurityParameterstoE_UTRAN := valueof(p_value)}
                value_ := {NASSecurityParameterstoE_UTRAN := valueof(p_value)}
            } // End of template m_nasSecurityParametersToEutran_IE
            } // End of template m_nasSecurityParametersToEutran_IE
            
            
            /**
             * @desc receive template for eNBStatusTransferTransparentContainer IE
             * @param p_value  eNBStatusTransferTransparentContainer value
             * @see ETSI TS 136 413 V13.4.0 Clause 9.2.1.31 eNBStatusTransferTransparentContainer
             */
            template (value) ProtocolIE m_eNBStatusTransferTransparentContainer_IE(
                                                   in template (value) ENB_StatusTransfer_TransparentContainer p_value,
                                                   in template (value) ProtocolIE.criticality p_criticality := reject
            ) := {
                id := S1AP_Constants.id_eNB_StatusTransfer_TransparentContainer,
                criticality := p_criticality,
                value_ := {ENB_StatusTransfer_TransparentContainer := valueof(p_value)}
            } // End of template m_eNBStatusTransferTransparentContainer_IE

            /**
             * @desc 
             */
            template (value) ENB_StatusTransfer_TransparentContainer m_eNBStatusTransferTransparentContainer (
                in template (value) Bearers_SubjectToStatusTransferList p_bearers_SubjectToStatusTransferList):= {
              bearers_SubjectToStatusTransferList := p_bearers_SubjectToStatusTransferList,
              iE_Extensions := omit
            }
//            /**
//             * @desc 
//             */
//            template (value) Bearers_SubjectToStatusTransfer_ItemIEs m_Bearers_SubjectToStatusTransfer_ItemIEs (
//                in template (value) Bearers_SubjectToStatusTransfer_Item p_bearers_SubjectToStatusTransfer,
//                in template (value) ProtocolIE.criticality p_criticality := ignore
//            
//            ):= {
//                id := S1AP_Constants.id_Bearers_SubjectToStatusTransfer_Item,
//                criticality := p_criticality,
//                value_ := {Bearers_SubjectToStatusTransfer_Item := valueof(p_bearers_SubjectToStatusTransfer)}
//            }
            
            template (value) Bearers_SubjectToStatusTransfer_Item m_Bearers_SubjectToStatusTransfer_Item(
                in template (value) E_RAB_ID p_e_RAB_ID,
                in template (value) COUNTvalue p_uL_COUNTvalue,
                in template (value) COUNTvalue p_dL_COUNTvalue
            ):= {
                e_RAB_ID:= p_e_RAB_ID,
                uL_COUNTvalue:=p_uL_COUNTvalue,
                dL_COUNTvalue:=p_dL_COUNTvalue,
                //ReceiveStatusofULPDCPSDUs
                receiveStatusofULPDCPSDUs := omit,
                iE_Extensions := omit
            }
             
            template (value) COUNTvalue m_COUNTvalue(
                in template (value) PDCP_SN p_PDCP_SN_value,
                in template (value) HFN p_HFN_value
            ):={
                pDCP_SN := valueof(p_PDCP_SN_value),
                hFN := valueof(p_HFN_value),
                iE_Extensions := omit
            }
            
            /**
            /**
             * @desc Send template for correlation ID IE
             * @desc Send template for correlation ID IE
             * @param p_value  UESecurityCapabilities value
             * @param p_value  UESecurityCapabilities value
+181 −0
Original line number Original line Diff line number Diff line
@@ -5763,6 +5763,187 @@ module S1AP_TCFunctions {
                log("*** " & __SCOPE__ & ": INFO: Postamble done. ***");
                log("*** " & __SCOPE__ & ": INFO: Postamble done. ***");
                
                
            } // End of function f_TC_S1AP_MME_HAS_13
            } // End of function f_TC_S1AP_MME_HAS_13

            /**
             * @desc Testcase function for TC_S1AP_MME_HAS_14
             */
            function f_TC_S1AP_MME_HAS_14() runs on S1APComponent { 
                // Local variables
                const Source_ToTarget_TransparentContainer c_source_ToTarget_TransparentContainer := '12121212'O;
                const Target_ToSource_TransparentContainer c_target_ToSource_TransparentContainer := '12121212'O;
                
                // Preamble
                f_S1AP_mme_init();
                // Preamble action: E-RAB Setup is exchanged.
                //f_rABSetup...;
                
                f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict()); 
                log("*** " & __SCOPE__ & ": INFO: Preamble done. ***");
                
                // Test body
                // sends a HANDOVER_REQUIRED
                f_send_PathSwitchRequest(
                    m_PathSwitchRequestIEs(
                    vc_eNB_UE_ID,
                    {m_E_RABToBeSwitchedDLItem(1,-,-,-)},
                    vc_MME_UE_ID,
                    m_eUTRAN_CGI('000001'O, //plmn id
                                 '0000000000000000000000000001'B ),//ci
                    m_TAI('000001'O,'0001'O),
                    m_UESecurityCapabilities('0101010101010101'B,'0101010101010101'B)
                ));
                 
                f_recv_PathSwitchRequestFailure(
                    mw_PathSwitchRequestFailureIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        -//cause
                ));
                
                f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict());
                
                // Postamble
                //f_rABSetupRelease...;
                f_postamble_S1AP_eNB();
                f_selfOrClientSyncAndVerdict(c_poDone, f_getVerdict()); 
                log("*** " & __SCOPE__ & ": INFO: Postamble done. ***");
                
            } // End of function f_TC_S1AP_MME_HAS_14
            
            /**
             * @desc Testcase function for TC_S1AP_MME_HAS_15
             */
            function f_TC_S1AP_MME_HAS_15() runs on S1APComponent { 
                // Local variables
                const Source_ToTarget_TransparentContainer c_source_ToTarget_TransparentContainer := '12121212'O;
                const Target_ToSource_TransparentContainer c_target_ToSource_TransparentContainer := '12121212'O;
                
                // Preamble
                f_S1AP_mme_init();
                // Preamble action: E-RAB Setup is exchanged.
                //f_rABSetup...;
                
                f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict()); 
                log("*** " & __SCOPE__ & ": INFO: Preamble done. ***");
                
                // Test body
                // sends a HANDOVER_REQUIRED
                f_send_HandoverRequired(
                    m_HandoverRequiredIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        intralte,
                        m_cause_ran(unspecified),
                        m_TargeteNB_ID(m_Global_ENB_ID('000001'O,
                                                       m_ENB_ID_macro),
                                       m_TAI('000001'O,
                                             '0001'O)),
                        c_source_ToTarget_TransparentContainer
                ));
                 
                f_recv_HandoverCommand(
                    mw_HandoverCommandIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        intralte,//handover_Type
                        c_target_ToSource_TransparentContainer//TargetToSourceTransparentContainer
                ));
                
                f_send_HandoverCancel(
                    m_HandoverCancelIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        m_cause_ran(unspecified)
                ));
                
                f_recv_HandoverCancelAck(
                    mw_HandoverCancelAckIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID
                ));
                
                f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict());
                
                // Postamble
                //f_rABSetupRelease...;
                f_postamble_S1AP_eNB();
                f_selfOrClientSyncAndVerdict(c_poDone, f_getVerdict()); 
                log("*** " & __SCOPE__ & ": INFO: Postamble done. ***");
                
            } // End of function f_TC_S1AP_MME_HAS_15
            
            /**
             * @desc Testcase function for TC_S1AP_MME_HAS_16
             */
            function f_TC_S1AP_MME_HAS_16() runs on S1APComponent { 
                // Local variables
                const Source_ToTarget_TransparentContainer c_source_ToTarget_TransparentContainer := '12121212'O;
                const Target_ToSource_TransparentContainer c_target_ToSource_TransparentContainer := '12121212'O;
                
                // Preamble
                f_S1AP_mme_init();
                // Preamble action: E-RAB Setup is exchanged.
                //f_rABSetup...;
                
                f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict()); 
                log("*** " & __SCOPE__ & ": INFO: Preamble done. ***");
                
                // Test body
                // sends a HANDOVER_REQUIRED
                f_send_HandoverRequired(
                    m_HandoverRequiredIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        intralte,
                        m_cause_ran(unspecified),
                        m_TargeteNB_ID(m_Global_ENB_ID('000001'O,
                                                       m_ENB_ID_macro),
                                       m_TAI('000001'O,
                                             '0001'O)),
                        c_source_ToTarget_TransparentContainer
                ));
                 
//                f_recv_HandoverCommand(
//                    mw_HandoverCommandIEs(
//                        vc_MME_UE_ID,
//                        vc_eNB_UE_ID,
//                        intralte,//handover_Type
//                        c_target_ToSource_TransparentContainer//TargetToSourceTransparentContainer
//                ));
                
                f_send_eNB_Status_Transfer(
                    m_eNB_Status_TransferIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        m_eNBStatusTransferTransparentContainer(
                          {{id:=89,//S1AP_Constants.id_Bearers_SubjectToStatusTransfer_Item,
                            criticality:=ignore,
                            value_:= {Bearers_SubjectToStatusTransfer_Item := valueof(
                                                 m_Bearers_SubjectToStatusTransfer_Item(1,
                                                                       m_COUNTvalue(0,0),
                                                                       m_COUNTvalue(0,0)))}
                           }
                          }
                        )
                ));
                
                f_recv_Mme_Status_Transfer(
                    mw_Mme_Status_TransferIEs(
                        vc_MME_UE_ID,
                        vc_eNB_UE_ID,
                        -
                ));
                
                f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict());
                
                // Postamble
                //f_rABSetupRelease...;
                f_postamble_S1AP_eNB();
                f_selfOrClientSyncAndVerdict(c_poDone, f_getVerdict()); 
                log("*** " & __SCOPE__ & ": INFO: Postamble done. ***");
                
            } // End of function f_TC_S1AP_MME_HAS_16
            
        } // End of group Handover_signalling_group
        } // End of group Handover_signalling_group
        
        
        /**
        /**