Change in ...osmo-ttcn3-hacks[master]: MGC_Test: test rtp directions separately in TC_ts101318_rfc5993_rtp_c...

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

dexter gerrit-no-reply at lists.osmocom.org
Tue Oct 1 12:17:47 UTC 2019


dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15641


Change subject: MGC_Test: test rtp directions separately in TC_ts101318_rfc5993_rtp_conversion
......................................................................

MGC_Test: test rtp directions separately in TC_ts101318_rfc5993_rtp_conversion

The testcase TC_ts101318_rfc5993_rtp_conversion tests the RTP packet
format conversion of ts101318 to rfc5993 and vice versa. At the moment
the testcase sends RTP packets in both directions at the same time. In
order to simplify the test and to make race conditions less likely, lets
test both directions separately and add some guard time.

Change-Id: Id9b69587f7fb5f6b0da072ac5f4863fd4111e597
---
M mgw/MGCP_Test.ttcn
1 file changed, 20 insertions(+), 6 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/41/15641/1

diff --git a/mgw/MGCP_Test.ttcn b/mgw/MGCP_Test.ttcn
index 86fc275..4f2d58e 100644
--- a/mgw/MGCP_Test.ttcn
+++ b/mgw/MGCP_Test.ttcn
@@ -1961,7 +1961,7 @@
 		f_vty_transceive(MGWVTY, "mgcp");
 		f_vty_transceive(MGWVTY, "rtp-patch rfc5993hr");
 
-		/* from us to MGW */
+		/* Connection #0 (Bidirectional) */
 		flow[0] := valueof(t_RtpFlow(mp_local_ip, mp_remote_ip, 111, "GSM-HR-08/8000"));
 		/* bind local RTP emulation sockets */
 		flow[0].em.portnr := 10000;
@@ -1971,7 +1971,7 @@
 		flow[0].rtp_cfg.tx_fixed_payload := '0b11b3eede60be4e3ec68838c7b5'O;
 		f_flow_create(RTPEM[0], ep, call_id, "sendrecv", flow[0]);
 
-		/* from MGW back to us */
+		/* Connection #1 (Bidirectional) */
 		flow[1] := valueof(t_RtpFlow(mp_local_ip, mp_remote_ip, 111, "GSM-HR-08/8000"));
 		flow[1].em.portnr := 20000;
 		flow[1].rtp_cfg	:= c_RtpemDefaultCfg;
@@ -1980,17 +1980,31 @@
 		flow[1].rtp_cfg.tx_fixed_payload := '000b11b3eede60be4e3ec68838c7b5'O;
 		f_flow_create(RTPEM[1], ep, call_id, "sendrecv", flow[1]);
 
-		f_rtpem_mode(RTPEM[1], RTPEM_MODE_BIDIR);
-		f_rtpem_mode(RTPEM[0], RTPEM_MODE_BIDIR);
-
+		/* Send RTP packets to connection #0, receive on connection #1 */
+		f_rtpem_mode(RTPEM[1], RTPEM_MODE_RXONLY);
+		f_sleep(0.5);
+		f_rtpem_mode(RTPEM[0], RTPEM_MODE_TXONLY);
 		f_sleep(1.0);
+		f_rtpem_mode(RTPEM[0], RTPEM_MODE_NONE);
+		f_sleep(0.5);
+		f_rtpem_mode(RTPEM[1], RTPEM_MODE_NONE);
 
+		/* Send RTP packets to connection #1, receive on connection #0 */
+		f_rtpem_mode(RTPEM[0], RTPEM_MODE_RXONLY);
+		f_sleep(0.5);
+		f_rtpem_mode(RTPEM[1], RTPEM_MODE_TXONLY);
+		f_sleep(1.0);
+		f_rtpem_mode(RTPEM[1], RTPEM_MODE_NONE);
+		f_sleep(0.5);
+		f_rtpem_mode(RTPEM[0], RTPEM_MODE_NONE);
+
+		/* Remove RTP flows and check statistics */
 		f_flow_delete(RTPEM[0]);
 		f_flow_delete(RTPEM[1], ep, call_id);
 
+		/* Check for errors */
 		stats[0] := f_rtpem_stats_get(RTPEM[0]);
 		stats[1] := f_rtpem_stats_get(RTPEM[1]);
-
 		f_rtpem_stats_err_check(stats[0]);
 		f_rtpem_stats_err_check(stats[1]);
 

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/15641
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Id9b69587f7fb5f6b0da072ac5f4863fd4111e597
Gerrit-Change-Number: 15641
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191001/f94b2f23/attachment.htm>


More information about the gerrit-log mailing list