blob: 34d7ebfd86546427c3ffa5d95ddc94b6687eb1b5 [file] [log] [blame]
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +01001Testing generation of GSM0808 messages
2Testing creating Layer3
Philipp Maierfa896ab2017-03-27 16:55:32 +02003Testing creating Layer3 (AoIP)
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +01004Testing creating Reset
Philipp Maier15596e22017-04-05 17:55:27 +02005Testing creating Reset Ack
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +01006Testing creating Clear Command
7Testing creating Clear Complete
Philipp Maierb478dd32017-03-29 15:50:05 +02008Testing creating Chipher Mode Command
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +01009Testing creating Cipher Complete
10Testing creating Cipher Reject
11Testing creating CM U
12Testing creating SAPI Reject
Philipp Maierc6144a22017-03-29 17:53:43 +020013Testing creating Assignment Request
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +010014Testing creating Assignment Complete
Philipp Maierfa896ab2017-03-27 16:55:32 +020015Testing creating Assignment Complete (AoIP)
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +010016Testing creating Assignment Failure
Philipp Maierfa896ab2017-03-27 16:55:32 +020017Testing creating Assignment Failure (AoIP)
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +010018Testing creating Clear Request
Philipp Maier3d48ec02017-03-29 17:37:55 +020019Testing creating Paging Request
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +010020Testing creating DTAP
21Testing prepend DTAP
Neels Hofmeyrdb2fa4e2018-04-13 04:11:20 +020022test_gsm0808_enc_dec_cell_id_list_lac: encoded: 1a 07 05 01 24 ab cd 56 78 (rc = 9)
Neels Hofmeyr74663d92018-03-23 01:46:42 +010023------- test_cell_id_list_add
24 cell_id_list cgi[0] = {
25 }
26
27gsm0808_cell_id_list_add(&cil, &lac1) --> rc = 1
28 cell_id_list lac[1] = {
29 0: 123
30 }
31
32gsm0808_cell_id_list_add(&cil, &lac1) --> rc = 0
33 cell_id_list lac[1] = {
34 0: 123
35 }
36
37gsm0808_cell_id_list_add(&cil, &lac2) --> rc = 2
38 cell_id_list lac[3] = {
39 0: 123
40 1: 456
41 2: 789
42 }
43
44gsm0808_cell_id_list_add(&cil, &lac2) --> rc = 0
45 cell_id_list lac[3] = {
46 0: 123
47 1: 456
48 2: 789
49 }
50
51gsm0808_cell_id_list_add(&cil, &cil) --> rc = 0
52 cell_id_list lac[3] = {
53 0: 123
54 1: 456
55 2: 789
56 }
57
58gsm0808_cell_id_list_add(&cil, &cgi1) --> rc = -22
59 cell_id_list lac[3] = {
60 0: 123
61 1: 456
62 2: 789
63 }
64
65can't add to BSS list
66 cell_id_list bss[0]
67
68gsm0808_cell_id_list_add(&cil, &lac1) --> rc = -22
69 cell_id_list bss[0]
70
71other types (including NO_CELL) take on new type iff empty
72 cell_id_list no_cell[0]
73
74gsm0808_cell_id_list_add(&cil, &cgi1) --> rc = 1
75 cell_id_list cgi[1] = {
76 0: 001-02-3-4
77 }
78
79gsm0808_cell_id_list_add(&cil, &cgi1) --> rc = 0
80 cell_id_list cgi[1] = {
81 0: 001-02-3-4
82 }
83
84gsm0808_cell_id_list_add(&cil, &cgi2) --> rc = 2
85 cell_id_list cgi[3] = {
86 0: 001-02-3-4
87 1: 001-002-3-4
88 2: 005-006-7-8
89 }
90
91gsm0808_cell_id_list_add(&cil, &cgi2) --> rc = 0
92 cell_id_list cgi[3] = {
93 0: 001-02-3-4
94 1: 001-002-3-4
95 2: 005-006-7-8
96 }
97
98cil.id_list_len = 126
99gsm0808_cell_id_list_add(&cil, &cgi2a) --> rc = 1
100cil.id_list_len = 127
101
102cil.id_list_len = 126
103gsm0808_cell_id_list_add(&cil, &cgi3) --> rc = -28
104cil.id_list_len = 127
105gsm0808_cell_id_list_add(&cil, &cgi2a) --> rc = -28
106cil.id_list_len = 127
107------- test_cell_id_list_add done
Neels Hofmeyr250e7f72018-04-13 03:30:14 +0200108test_gsm0808_enc_dec_cell_id_lac: encoded: 05 03 05 01 24 (rc = 5)
109test_gsm0808_enc_dec_cell_id_bss: encoded: 05 01 06 (rc = 3)
110test_gsm0808_enc_dec_cell_id_no_cell: encoded: 05 01 03 (rc = 3)
111test_gsm0808_enc_dec_cell_id_lai_and_lac: encoded: 05 06 04 21 63 54 23 42 (rc = 8)
112test_gsm0808_enc_dec_cell_id_ci: encoded: 05 03 02 04 23 (rc = 5)
113test_gsm0808_enc_dec_cell_id_lac_and_ci: encoded: 05 05 01 04 23 02 35 (rc = 7)
114test_gsm0808_enc_dec_cell_id_global: encoded: 05 08 00 21 63 54 23 42 04 23 (rc = 10)
Holger Hans Peter Freyther97510812012-01-22 13:36:52 +0100115Done