MGCP_Test: Add VTY access
The MGCP_Test testsuite currenty lacks VTY access capabilities, lets add them so that future testcases can access the VTY in order to change options on the fly. Depends: osmo-ttcn3-hacks Ife949c61156222de3026280071226ef6f5dbd959 Change-Id: If383f81af3306f8f5bdf50152498ae1303d390df Related: OS#3807
This commit is contained in:
parent
07e8dde671
commit
6137c32e05
|
@ -2,12 +2,22 @@
|
|||
FileMask := LOG_ALL | TTCN_MATCHING;
|
||||
|
||||
[TESTPORT_PARAMETERS]
|
||||
*.MGWVTY.CTRL_MODE := "client"
|
||||
*.MGWVTY.CTRL_HOSTNAME := "127.0.0.1"
|
||||
*.MGWVTY.CTRL_PORTNUM := "4243"
|
||||
*.MGWVTY.CTRL_LOGIN_SKIPPED := "yes"
|
||||
*.MGWVTY.CTRL_DETECT_SERVER_DISCONNECTED := "yes"
|
||||
*.MGWVTY.CTRL_READMODE := "buffered"
|
||||
*.MGWVTY.CTRL_CLIENT_CLEANUP_LINEFEED := "yes"
|
||||
*.MGWVTY.CTRL_DETECT_CONNECTION_ESTABLISHMENT_RESULT := "yes"
|
||||
*.MGWVTY.PROMPT1 := "OsmoMGW> "
|
||||
|
||||
[MODULE_PARAMETERS]
|
||||
mp_local_udp_port := 2727;
|
||||
mp_local_ip:= "127.0.0.1";
|
||||
mp_remote_udp_port := 2427;
|
||||
mp_remote_ip:= "127.0.0.1";
|
||||
Osmocom_VTY_Functions.mp_prompt_prefix := "OsmoMGW";
|
||||
|
||||
[MAIN_CONTROLLER]
|
||||
|
||||
|
|
|
@ -9,6 +9,12 @@ module MGCP_Test {
|
|||
import from RTP_CodecPort_CtrlFunct all;
|
||||
import from RTP_Emulation all;
|
||||
import from IPL4asp_Types all;
|
||||
import from General_Types all;
|
||||
import from Native_Functions all;
|
||||
import from IPCP_Types all;
|
||||
import from IP_Types all;
|
||||
import from Osmocom_VTY_Functions all;
|
||||
import from TELNETasp_PortType all;
|
||||
|
||||
const charstring c_mgw_domain := "mgw";
|
||||
const charstring c_mgw_ep_rtpbridge := "rtpbridge/";
|
||||
|
@ -24,6 +30,8 @@ module MGCP_Test {
|
|||
|
||||
var RTP_Emulation_CT vc_RTPEM[3];
|
||||
port RTPEM_CTRL_PT RTPEM[3];
|
||||
|
||||
port TELNETasp_PT MGWVTY;
|
||||
};
|
||||
|
||||
function get_next_trans_id() runs on dummy_CT return MgcpTransId {
|
||||
|
@ -44,6 +52,12 @@ module MGCP_Test {
|
|||
PortNumber mp_local_rtp_port_base := 10000;
|
||||
}
|
||||
|
||||
private function f_init_vty() runs on dummy_CT {
|
||||
map(self:MGWVTY, system:MGWVTY);
|
||||
f_vty_set_prompts(MGWVTY);
|
||||
f_vty_transceive(MGWVTY, "enable");
|
||||
}
|
||||
|
||||
private function f_rtpem_init(inout RTP_Emulation_CT comp_ref, integer i)
|
||||
runs on dummy_CT {
|
||||
comp_ref := RTP_Emulation_CT.create("RTPEM" & int2str(i));
|
||||
|
@ -85,6 +99,8 @@ module MGCP_Test {
|
|||
/* do a DLCX on all connections of the EP */
|
||||
f_dlcx_ignore(valueof(ep));
|
||||
}
|
||||
|
||||
f_init_vty();
|
||||
}
|
||||
|
||||
testcase TC_selftest() runs on dummy_CT {
|
||||
|
|
|
@ -29,10 +29,20 @@ DIR=$BASEDIR/titan.ProtocolModules.RTP/src
|
|||
FILES="RTP_EncDec.cc RTP_Types.ttcn"
|
||||
gen_links $DIR $FILES
|
||||
|
||||
DIR=$BASEDIR/titan.ProtocolModules.IP/src
|
||||
FILES="IP_EncDec.cc IP_Types.ttcn"
|
||||
gen_links $DIR $FILES
|
||||
|
||||
DIR=$BASEDIR/titan.TestPorts.TELNETasp/src
|
||||
FILES="TELNETasp_PT.cc TELNETasp_PT.hh TELNETasp_PortType.ttcn"
|
||||
gen_links $DIR $FILES
|
||||
|
||||
DIR=../library
|
||||
FILES="Misc_Helpers.ttcn General_Types.ttcn Osmocom_Types.ttcn MGCP_Types.ttcn MGCP_Templates.ttcn MGCP_CodecPort.ttcn
|
||||
MGCP_CodecPort_CtrlFunct.ttcn MGCP_CodecPort_CtrlFunctDef.cc "
|
||||
FILES+="RTP_CodecPort.ttcn RTP_Emulation.ttcn IuUP_Types.ttcn IuUP_Emulation.ttcn IuUP_EncDec.cc "
|
||||
FILES+="Native_Functions.ttcn Native_FunctionDefs.cc IPCP_Types.ttcn "
|
||||
FILES+="Osmocom_VTY_Functions.ttcn "
|
||||
gen_links $DIR $FILES
|
||||
|
||||
ignore_pp_results
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#!/bin/sh
|
||||
|
||||
FILES="*.ttcn SDP_EncDec.cc *.c MGCP_CodecPort_CtrlFunctDef.cc IPL4asp_PT.cc IPL4asp_discovery.cc TCCConversion.cc TCCInterface.cc RTP_EncDec.cc RTP_CodecPort_CtrlFunctDef.cc IuUP_EncDec.cc "
|
||||
FILES="*.ttcn SDP_EncDec.cc *.c MGCP_CodecPort_CtrlFunctDef.cc IPL4asp_PT.cc IPL4asp_discovery.cc TCCConversion.cc TCCInterface.cc RTP_EncDec.cc RTP_CodecPort_CtrlFunctDef.cc IuUP_EncDec.cc Native_FunctionDefs.cc TELNETasp_PT.cc IP_EncDec.cc "
|
||||
|
||||
../regen-makefile.sh MGCP_Test.ttcn $FILES
|
||||
|
|
Loading…
Reference in New Issue