diff options
author | Vadim Yanitskiy <vyanitskiy@sysmocom.de> | 2020-05-29 15:21:50 +0700 |
---|---|---|
committer | laforge <laforge@osmocom.org> | 2020-05-29 20:02:49 +0000 |
commit | 438939029d1249d7b8845f665b7d6d456c6d49e9 (patch) | |
tree | cb8778b3aa60e1eea0e616fea3946162f4fbd3f0 | |
parent | 28cabc4cc1d0ebc24de0fb5d729dc66005bac965 (diff) |
PCU: revert changes to f_TC_egprs_pkt_chan_req(), fix tests
I noticed that TC_egprs_pkt_chan_req_reject_exhaustion has started
to fail since the refactoring change [1]. As it turned out, this
test case does not init a GprsMs instance, which is needed by a
function it depends on - f_TC_egprs_pkt_chan_req().
I don't really see the point of using the GprsMs abstraction for
such small test cases sending just a few messages, which do not
require us to keep any state. Let's just revert those changes,
and keep using the low level API.
[1] Ib3fee37580f0ea0530a659dec83656799bf57288
Change-Id: I4f32c138e7587e68d2d35d13d13c044893fec4b2
-rw-r--r-- | pcu/PCU_Tests.ttcn | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/pcu/PCU_Tests.ttcn b/pcu/PCU_Tests.ttcn index 061b868c..5fb4b2bf 100644 --- a/pcu/PCU_Tests.ttcn +++ b/pcu/PCU_Tests.ttcn @@ -1509,20 +1509,17 @@ testcase TC_paging_ps_from_sgsn_ptp() runs on RAW_PCU_Test_CT { } private function f_TC_egprs_pkt_chan_req(in EGPRSPktChRequest req, - template GsmRrMessage t_imm_ass := ?) + template GsmRrMessage t_imm_ass := ?, + PCUIF_BurstType bt := BURST_TYPE_1) runs on RAW_PCU_Test_CT { + var GsmRrMessage rr_msg; var uint16_t ra11; - var GprsMS ms; - - ms := g_ms[0]; /* We only use first MS in this test */ ra11 := enc_EGPRSPktChRequest2uint(req); - f_ms_use_ra(ms, ra11, ra_is_11bit := 1); log("Sending EGPRS Packet Channel Request (", ra11, "): ", req); - f_ms_establish_ul_tbf(ms); - - if (not match(ms.ul_tbf.rr_imm_ass, t_imm_ass)) { + rr_msg := f_establish_tbf(ra := ra11, is_11bit := 1, burst_type := bt); + if (not match(rr_msg, t_imm_ass)) { setverdict(fail, "Immediate Assignment does not match"); f_shutdown(__BFILE__, __LINE__); } @@ -1535,9 +1532,6 @@ testcase TC_egprs_pkt_chan_req_signalling() runs on RAW_PCU_Test_CT { var template IaRestOctets rest; var template EgprsUlAss ul_ass; - /* Initialize GPRS MS side */ - f_init_gprs_ms(); - /* Initialize the PCU interface abstraction */ f_init_raw(testcasename()); @@ -1566,9 +1560,6 @@ testcase TC_egprs_pkt_chan_req_one_phase() runs on RAW_PCU_Test_CT { var template IaRestOctets rest; var template EgprsUlAss ul_ass; - /* Initialize GPRS MS side */ - f_init_gprs_ms(); - /* Initialize the PCU interface abstraction */ f_init_raw(testcasename()); @@ -1603,9 +1594,6 @@ testcase TC_egprs_pkt_chan_req_two_phase() runs on RAW_PCU_Test_CT { var template IaRestOctets rest; var template EgprsUlAss ul_ass; - /* Initialize GPRS MS side */ - f_init_gprs_ms(); - /* Initialize the PCU interface abstraction */ f_init_raw(testcasename()); |