summaryrefslogtreecommitdiffstats
path: root/msc/MSC_Tests.ttcn
diff options
context:
space:
mode:
authorVadim Yanitskiy <axilirator@gmail.com>2019-12-13 15:45:44 +0900
committerfixeria <axilirator@gmail.com>2020-01-03 12:27:17 +0000
commit04dd5f7aa02c40279f2372cfcb717f602de161ce (patch)
tree8cc2be3fba75859a137b864f5f84f64afeaeb056 /msc/MSC_Tests.ttcn
parenta52347ca32e00ac71415125219abbcd7b02be79e (diff)
MSC_Tests.ttcn: fix: verify the contents of SM-RP-DA/OA for MO/MT SMS
Diffstat (limited to 'msc/MSC_Tests.ttcn')
-rw-r--r--msc/MSC_Tests.ttcn26
1 files changed, 18 insertions, 8 deletions
diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn
index f430335..e0d9c7f 100644
--- a/msc/MSC_Tests.ttcn
+++ b/msc/MSC_Tests.ttcn
@@ -2166,10 +2166,17 @@ runs on BSC_ConnHdlr {
var template GSUP_PDU mo_forwardSM := tr_GSUP_MO_FORWARD_SM_REQ(
imsi := g_pars.imsi,
sm_rp_mr := spars.rp.msg_ref,
- /* FIXME: extract SM-RP-DA from spars.rp.dest */
- sm_rp_da := tr_GSUP_SM_RP_DA_SMSC_ADDR(?),
- /* FIXME: MSISDN coding troubles */
- sm_rp_oa := tr_GSUP_SM_RP_OA_MSISDN(?),
+ /* SM-RP-DA: SMSC address */
+ sm_rp_da := tr_GSUP_SM_RP_DA_SMSC_ADDR(t_GSUP_SM_RP_Addr(
+ number := spars.rp.smsc_addr.rP_NumberDigits,
+ npi := spars.rp.smsc_addr.rP_NumberingPlanIdentification,
+ ton := spars.rp.smsc_addr.rP_TypeOfNumber,
+ ext := spars.rp.smsc_addr.rP_Ext)),
+ /* SM-RP-OA: subscriber's MSISDN (filled in by MSC) */
+ sm_rp_oa := tr_GSUP_SM_RP_OA_MSISDN(t_GSUP_SM_RP_Addr(
+ number := g_pars.msisdn,
+ /* NOTE: MSISDN in g_pars lacks this info, assuming defaults */
+ npi := '0001'B, ton := '001'B, ext := '1'B)),
/* TODO: can we use decmatch here? */
sm_rp_ui := sm_tpdu
);
@@ -2269,15 +2276,18 @@ testcase TC_gsup_mo_smma() runs on MTC_CT {
private function f_gsup_forwardSM_req(SmsParameters spars, OCT1 mms := '00'O)
runs on BSC_ConnHdlr {
var GSUP_SM_RP_Addr msisdn := valueof(t_GSUP_SM_RP_Addr(g_pars.msisdn));
+ var GSUP_SM_RP_Addr smsc := valueof(t_GSUP_SM_RP_Addr(
+ number := spars.rp.smsc_addr.rP_NumberDigits,
+ npi := spars.rp.smsc_addr.rP_NumberingPlanIdentification,
+ ton := spars.rp.smsc_addr.rP_TypeOfNumber,
+ ext := spars.rp.smsc_addr.rP_Ext));
GSUP.send(ts_GSUP_MT_FORWARD_SM_REQ(
imsi := g_pars.imsi,
/* NOTE: MSC should assign RP-MR itself */
sm_rp_mr := 'FF'O,
- /* FIXME: extract SM-RP-DA from spars.rp.dest */
- /* TODO: fix encoding of ts_GSUP_SM_RP_DA_IMSI */
sm_rp_da := valueof(ts_GSUP_SM_RP_DA_MSISDN(msisdn)),
- sm_rp_oa := valueof(ts_GSUP_SM_RP_OA_SMSC_ADDR(msisdn)),
+ sm_rp_oa := valueof(ts_GSUP_SM_RP_OA_SMSC_ADDR(smsc)),
/* Encoded SMS TPDU (taken from Wireshark)
* FIXME: we should encode spars somehow */
sm_rp_ui := '00068021436500008111328130858200'O,
@@ -4656,7 +4666,7 @@ runs on BSC_ConnHdlr {
/* Expect CP-DATA(RP-DATA(SMS-DELIVER)) */
tp_mt := tr_SMS_DELIVER(?, spars.tp.ud, spars.tp.pid, spars.tp.dcs, ?);
- rp_mt := tr_RP_DATA_MT(?, ?, omit, tp_mt);
+ rp_mt := tr_RP_DATA_MT(?, spars.rp.smsc_addr, omit, tp_mt);
l3_mt := tr_ML3_MT_SMS(?, c_TIF_ORIG, tr_CP_DATA_MT(rp_mt));
SGsAP.receive(l3_mt) -> value sgsap_l3_mt;