diff options
author | Neels Hofmeyr <neels@hofmeyr.de> | 2018-04-13 04:11:20 +0200 |
---|---|---|
committer | Neels Hofmeyr <neels@hofmeyr.de> | 2018-04-13 05:38:48 +0200 |
commit | db2fa4e0d5a112adedf17948a73b481c69022e14 (patch) | |
tree | 6284f312a6a167e5cb9c73b8729c9a1484c5a32b /tests/gsm0808 | |
parent | 066473fe3635ad98ebc17d0bc2a320712e0b6cdd (diff) |
test_gsm0808_enc_dec_cell_id_list_lac(): populate all LACs
Change-Id: I7535166a2827c03a954fe72d5d99217e4f25868f
Diffstat (limited to 'tests/gsm0808')
-rw-r--r-- | tests/gsm0808/gsm0808_test.c | 6 | ||||
-rw-r--r-- | tests/gsm0808/gsm0808_test.ok | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/gsm0808/gsm0808_test.c b/tests/gsm0808/gsm0808_test.c index 41d85a86..a9ab72bc 100644 --- a/tests/gsm0808/gsm0808_test.c +++ b/tests/gsm0808/gsm0808_test.c @@ -768,13 +768,13 @@ static void test_gsm0808_enc_dec_cell_id_list_lac() memset(&enc_cil, 0, sizeof(enc_cil)); enc_cil.id_discr = CELL_IDENT_LAC; enc_cil.id_list[0].lac = 0x0124; - enc_cil.id_list[0].lac = 0xABCD; - enc_cil.id_list[0].lac = 0x5678; + enc_cil.id_list[1].lac = 0xABCD; + enc_cil.id_list[2].lac = 0x5678; enc_cil.id_list_len = 3; msg = msgb_alloc(1024, "output buffer"); rc_enc = gsm0808_enc_cell_id_list2(msg, &enc_cil); - EXPECT_ENCODED("1a 07 05 56 78 00 00 00 00"); + EXPECT_ENCODED("1a 07 05 01 24 ab cd 56 78"); rc_dec = gsm0808_dec_cell_id_list2(&dec_cil, msg->data + 2, msg->len - 2); OSMO_ASSERT(rc_dec == 7); diff --git a/tests/gsm0808/gsm0808_test.ok b/tests/gsm0808/gsm0808_test.ok index 0ec6d23f..34d7ebfd 100644 --- a/tests/gsm0808/gsm0808_test.ok +++ b/tests/gsm0808/gsm0808_test.ok @@ -19,7 +19,7 @@ Testing creating Clear Request Testing creating Paging Request Testing creating DTAP Testing prepend DTAP -test_gsm0808_enc_dec_cell_id_list_lac: encoded: 1a 07 05 56 78 00 00 00 00 (rc = 9) +test_gsm0808_enc_dec_cell_id_list_lac: encoded: 1a 07 05 01 24 ab cd 56 78 (rc = 9) ------- test_cell_id_list_add cell_id_list cgi[0] = { } |