Harald Welte has submitted this change and it was merged.

Change subject: test_gsm0808_enc_dec_cell_id_list_lac(): populate all LACs
......................................................................


test_gsm0808_enc_dec_cell_id_list_lac(): populate all LACs

Change-Id: I7535166a2827c03a954fe72d5d99217e4f25868f
---
M tests/gsm0808/gsm0808_test.c
M tests/gsm0808/gsm0808_test.ok
2 files changed, 4 insertions(+), 4 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/tests/gsm0808/gsm0808_test.c b/tests/gsm0808/gsm0808_test.c
index 41d85a8..a9ab72b 100644
--- a/tests/gsm0808/gsm0808_test.c
+++ b/tests/gsm0808/gsm0808_test.c
@@ -768,13 +768,13 @@
        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 0ec6d23..34d7ebf 100644
--- a/tests/gsm0808/gsm0808_test.ok
+++ b/tests/gsm0808/gsm0808_test.ok
@@ -19,7 +19,7 @@
 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] = {
      }

-- 
To view, visit https://gerrit.osmocom.org/7791
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I7535166a2827c03a954fe72d5d99217e4f25868f
Gerrit-PatchSet: 3
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofm...@sysmocom.de>
Gerrit-Reviewer: Harald Welte <lafo...@gnumonks.org>
Gerrit-Reviewer: Jenkins Builder

Reply via email to