Change in osmo-ttcn3-hacks[master]: hlr: add TC_MSLookup_mDNS_service_GSUP_HLR_proxy

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/.

osmith gerrit-no-reply at lists.osmocom.org
Thu Jan 30 15:52:06 UTC 2020


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


Change subject: hlr: add TC_MSLookup_mDNS_service_GSUP_HLR_proxy
......................................................................

hlr: add TC_MSLookup_mDNS_service_GSUP_HLR_proxy

Ask proxy HLR about gsup.hlr service, and expect no answer.

Related: OS#4380
Change-Id: Ic42c909e6540b2294b1109dc19c1df348224457b
---
M hlr/HLR_Tests.ttcn
1 file changed, 42 insertions(+), 0 deletions(-)



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

diff --git a/hlr/HLR_Tests.ttcn b/hlr/HLR_Tests.ttcn
index c8c6712..e00bd8b 100644
--- a/hlr/HLR_Tests.ttcn
+++ b/hlr/HLR_Tests.ttcn
@@ -1758,6 +1758,47 @@
 	vc_conn.done;
 }
 
+/* Ask proxy HLR about gsup.hlr service, and expect no answer. */
+private function f_TC_MSLookup_mDNS_service_GSUP_HLR_proxy() runs on HLR_ConnHdlr {
+	timer T;
+	var integer id := f_rnd_int(65535); /* mDNS packet ID */
+	var charstring domain := "gsup.hlr." & hex2str(g_pars.sub.imsi) & ".imsi.mdns.osmocom.org";
+
+	f_perform_UL_proxy(g_pars.sub.imsi, g_pars.sub.msisdn, OSMO_GSUP_CN_DOMAIN_CS);
+
+	/* Send mDNS query, expect timeout */
+	mDNS.send(ts_MSLookup_mDNS_query(id, domain));
+	T.start(1.0);
+	alt {
+	[] mDNS.receive(tr_MSLookup_mDNS_result_IPv4(id, domain, f_enc_IPv4(mp_hlr_ip), mp_hlr_gsup_port)) {
+		setverdict(fail, "mslookup result received from proxy HLR for gsup.hlr service");
+		}
+	[] mDNS.receive(MSLookup_mDNS:?) {
+		repeat;
+		}
+	[] T.timeout {
+		setverdict(pass);
+		}
+	}
+}
+testcase TC_MSLookup_mDNS_service_GSUP_HLR_proxy() runs on test_CT {
+	var hexstring imsi := f_rnd_imsi('26242'H);
+	var hexstring msisdn := '49161'H & f_rnd_hexstring(7, 9);
+	var HLR_ConnHdlr vc_conn;
+	var HLR_ConnHdlrPars pars := valueof(t_Pars(imsi, msisdn));
+
+	f_init(false, true);
+	f_vty_config(VTY, "mslookup", "mdns bind");
+	vc_conn := f_start_handler(refers(f_TC_MSLookup_mDNS_service_GSUP_HLR_proxy), pars, true);
+
+	timer T := 3.0;
+	T.start;
+	alt {
+	[] vc_conn.done {}
+	[] T.timeout { setverdict(fail, "Timeout"); mtc.stop; };
+	}
+}
+
 /* TODO:
   * UL with ISD error
   * UL with ISD timeout
@@ -1808,6 +1849,7 @@
 		execute( TC_MSLookup_mDNS_service_other_home() );
 		execute( TC_MSLookup_GSUP_proxy() );
 		execute( TC_MSLookup_mDNS_service_GSUP_HLR_home() );
+		execute( TC_MSLookup_mDNS_service_GSUP_HLR_proxy() );
 	}
 };
 

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/17074
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: Ic42c909e6540b2294b1109dc19c1df348224457b
Gerrit-Change-Number: 17074
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200130/8203eb70/attachment.htm>


More information about the gerrit-log mailing list