tests/tbf: test_tbf_dl_llc_loss(): Fix wrong param passed and wrong expectancies
The DL-TBF in the test gets its TS allocated on TS4 (only that one is
enabled through setup_bts(bts, ts_no=4)), and hence it makes no sense to
ask it to send data on TS7.
Change-Id: Ibe6fc073b7438b8024c4d3ddb0e60c6112752351
diff --git a/tests/tbf/TbfTest.cpp b/tests/tbf/TbfTest.cpp
index 7067201..ba357e3 100644
--- a/tests/tbf/TbfTest.cpp
+++ b/tests/tbf/TbfTest.cpp
@@ -587,7 +587,7 @@
OSMO_ASSERT(ms_dl_tbf(ms) != NULL);
- /* Here PCU would answer with data_cnf and trigger
+ /* Here BTS would answer with data_cnf and trigger
* bts_rcv_imm_ass_cnf(), which would trigger TBF_EV_ASSIGN_PCUIF_CNF.
* That in turn would set up timer X2002. Finally, X2002 timeout
* moves it to FLOW state. We set X2002 timeout to 0 here to get
@@ -606,12 +606,13 @@
0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01 },
{ 0x07, 0x00, 0x02, 0x4d, 0x02, 0x02, 0x02,
0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02 },
- { 0x07, 0x01, 0x04, 0x4d, 0x03, 0x03, 0x03,
+ /* On last DL block, PCU requests polling (DL ACK/NACK): S/P 1 and RRBP 01, hence 0x07 becomes 0xf1 */
+ { 0x1f, 0x01, 0x04, 0x4d, 0x03, 0x03, 0x03,
0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03 },
};
while (ms_dl_tbf(ms)->have_data()) {
- msg = ms_dl_tbf(ms)->create_dl_acked_block(fn += 4, 7);
+ msg = ms_dl_tbf(ms)->create_dl_acked_block(fn += 4, ts_no);
fprintf(stderr, "MSG = %s\n", msgb_hexdump(msg));
if (!msgb_eq_data_print(msg, exp[expected_data - 1], GSM_MACBLOCK_LEN))
fprintf(stderr, "%s failed at %u\n", __func__, expected_data);