[RICPLT-2165] Add rnibDataService to support retries
[ric-plt/e2mgr.git] / E2Manager / converters / x2setupResponseToProtobuf_test.go
1 /*******************************************************************************
2  *
3  *   Copyright (c) 2019 AT&T Intellectual Property.
4  *
5  *   Licensed under the Apache License, Version 2.0 (the "License");
6  *   you may not use this file except in compliance with the License.
7  *   You may obtain a copy of the License at
8  *
9  *       http://www.apache.org/licenses/LICENSE-2.0
10  *
11  *   Unless required by applicable law or agreed to in writing, software
12  *   distributed under the License is distributed on an "AS IS" BASIS,
13  *   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  *   See the License for the specific language governing permissions and
15  *   limitations under the License.
16  *
17  *******************************************************************************/
18 package converters
19
20 import (
21         "e2mgr/e2pdus"
22         "e2mgr/logger"
23         "fmt"
24         "gerrit.o-ran-sc.org/r/ric-plt/nodeb-rnib.git/entities"
25         "strings"
26         "testing"
27 )
28
29 /*
30 Test permutations of x2 setup response to protobuf enb
31  */
32
33 func TestUnpackX2SetupResponseAndExtract(t *testing.T) {
34         logger, _ := logger.InitLogger(logger.InfoLevel)
35
36         var testCases = []struct {
37                 key       *entities.GlobalNbId
38                 enb       string
39                 packedPdu string
40                 failure   error
41         }{
42                 {
43                         key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
44                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD ] []",
45                         /*
46                                 X2AP-PDU:
47                                  successfulOutcome_t
48                                   procedureCode_t = 0x6
49                                   criticality_t = 0
50                                   X2SetupResponse
51                                    protocolIEs_t:
52                                     ProtocolIE_Container_elm
53                                      id_t = 0x15
54                                      criticality_t = 0
55                                      GlobalENB-ID
56                                       pLMN_Identity_t = 02 f8 29
57                                       eNB_ID_t:
58                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
59                                     ProtocolIE_Container_elm
60                                      id_t = 0x14
61                                      criticality_t = 0
62                                      ServedCells:
63                                       ServedCells_elm
64                                        servedCellInfo_t
65                                         pCI_t = 0x63
66                                         cellId_t
67                                          pLMN_Identity_t = 02 f8 29
68                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
69                                         tAC_t = 01 02
70                                         broadcastPLMNs_t:
71                                          BroadcastPLMNs_Item_elm = 02 f8 29
72                                         eUTRA_Mode_Info_t:
73                                          fDD_t
74                                           uL_EARFCN_t = 0x1
75                                           dL_EARFCN_t = 0x1
76                                           uL_Transmission_Bandwidth_t = 0x3
77                                           dL_Transmission_Bandwidth_t = 0x3`
78                         */
79                         packedPdu: "2006002a000002001500080002f82900007a8000140017000000630002f8290007ab50102002f829000001000133"},
80                 {
81                         key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
82                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD ] []",
83                         /*
84                                 X2AP-PDU:
85                                  successfulOutcome_t
86                                   procedureCode_t = 0x6
87                                   criticality_t = 0
88                                   X2SetupResponse
89                                    protocolIEs_t:
90                                     ProtocolIE_Container_elm
91                                      id_t = 0x15
92                                      criticality_t = 0
93                                      GlobalENB-ID
94                                       pLMN_Identity_t = 02 f8 29
95                                       eNB_ID_t:
96                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
97                                     ProtocolIE_Container_elm
98                                      id_t = 0x14
99                                      criticality_t = 0
100                                      ServedCells:
101                                       ServedCells_elm
102                                        servedCellInfo_t
103                                         pCI_t = 0x63
104                                         cellId_t
105                                          pLMN_Identity_t = 02 f8 29
106                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
107                                         tAC_t = 01 02
108                                         broadcastPLMNs_t:
109                                          BroadcastPLMNs_Item_elm = 02 f8 29
110                                         eUTRA_Mode_Info_t:
111                                          fDD_t
112                                           uL_EARFCN_t = 0x1
113                                           dL_EARFCN_t = 0x1
114                                           uL_Transmission_Bandwidth_t = 0x3
115                                           dL_Transmission_Bandwidth_t = 0x3
116                                       ServedCells_elm
117                                        servedCellInfo_t
118                                         pCI_t = 0x64
119                                         cellId_t
120                                          pLMN_Identity_t = 02 f9 29
121                                          eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
122                                         tAC_t = 02 03
123                                         broadcastPLMNs_t:
124                                          BroadcastPLMNs_Item_elm = 02 f8 29
125                                          BroadcastPLMNs_Item_elm = 02 f9 29
126                                         eUTRA_Mode_Info_t:
127                                          fDD_t
128                                           uL_EARFCN_t = 0x2
129                                           dL_EARFCN_t = 0x3
130                                           uL_Transmission_Bandwidth_t = 0x4
131                                           dL_Transmission_Bandwidth_t = 0x4
132                         */
133                         packedPdu: "20060043000002001500080002f82900007a8000140030010000630002f8290007ab50102002f8290000010001330000640002f9290007ac50203202f82902f929000002000344"},
134
135                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
136                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD ] []",
137                         /*
138                                 X2AP-PDU:
139                                  successfulOutcome_t
140                                   procedureCode_t = 0x6
141                                   criticality_t = 0
142                                   X2SetupResponse
143                                    protocolIEs_t:
144                                     ProtocolIE_Container_elm
145                                      id_t = 0x15
146                                      criticality_t = 0
147                                      GlobalENB-ID
148                                       pLMN_Identity_t = 02 f8 29
149                                       eNB_ID_t:
150                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
151                                     ProtocolIE_Container_elm
152                                      id_t = 0x14
153                                      criticality_t = 0
154                                      ServedCells:
155                                       ServedCells_elm
156                                        servedCellInfo_t
157                                         pCI_t = 0x63
158                                         cellId_t
159                                          pLMN_Identity_t = 02 f8 29
160                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
161                                         tAC_t = 01 02
162                                         broadcastPLMNs_t:
163                                          BroadcastPLMNs_Item_elm = 02 f8 29
164                                         eUTRA_Mode_Info_t:
165                                          fDD_t
166                                           uL_EARFCN_t = 0x1
167                                           dL_EARFCN_t = 0x1
168                                           uL_Transmission_Bandwidth_t = 0x3
169                                           dL_Transmission_Bandwidth_t = 0x3
170                                           iE_Extensions_t:
171                                            ProtocolExtensionContainer_elm
172                                             id_t = 0x5f  //ul_EARFCN
173                                             criticality_t = 0
174                                             EARFCNExtension = 0x2
175                         */
176                         packedPdu: "20060033000002001500080002f82900007a8000140020000000630002f8290007ab50102002f8291000010001330000005f0003800102"},
177                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
178                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD ] [02f729:0203 02f929:0304]",
179                         /*
180                                 X2AP-PDU:
181                                  successfulOutcome_t
182                                   procedureCode_t = 0x6
183                                   criticality_t = 0
184                                   X2SetupResponse
185                                    protocolIEs_t:
186                                     ProtocolIE_Container_elm
187                                      id_t = 0x15
188                                      criticality_t = 0
189                                      GlobalENB-ID
190                                       pLMN_Identity_t = 02 f8 29
191                                       eNB_ID_t:
192                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
193                                     ProtocolIE_Container_elm
194                                      id_t = 0x14
195                                      criticality_t = 0
196                                      ServedCells:
197                                       ServedCells_elm
198                                        servedCellInfo_t
199                                         pCI_t = 0x63
200                                         cellId_t
201                                          pLMN_Identity_t = 02 f8 29
202                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
203                                         tAC_t = 01 02
204                                         broadcastPLMNs_t:
205                                          BroadcastPLMNs_Item_elm = 02 f8 29
206                                         eUTRA_Mode_Info_t:
207                                          fDD_t
208                                           uL_EARFCN_t = 0x1
209                                           dL_EARFCN_t = 0x1
210                                           uL_Transmission_Bandwidth_t = 0x3
211                                           dL_Transmission_Bandwidth_t = 0x3
212                                     ProtocolIE_Container_elm
213                                      id_t = 0x18
214                                      criticality_t = 0
215                                      GUGroupIDList:
216                                       GUGroupIDList_elm
217                                        pLMN_Identity_t = 02 f7 29
218                                        mME_Group_ID_t = 02 03
219                                       GUGroupIDList_elm
220                                        pLMN_Identity_t = 02 f9 29
221                                        mME_Group_ID_t = 03 04
222                         */
223                         packedPdu: "2006003a000003001500080002f82900007a8000140017000000630002f8290007ab50102002f8290000010001330018000c1002f72902030002f9290304"},
224
225                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
226                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<tdd:<ear_fcn:1 transmission_bandwidth:BW50 subframe_assignment:SA2 special_subframe_info:<special_subframe_patterns:SSP4 cyclic_prefix_dl:NORMAL cyclic_prefix_ul:EXTENDED > > > eutra_mode:TDD ] []",
227                         /*
228                                 X2AP-PDU:
229                                  successfulOutcome_t
230                                   procedureCode_t = 0x6
231                                   criticality_t = 0
232                                   X2SetupResponse
233                                    protocolIEs_t:
234                                     ProtocolIE_Container_elm
235                                      id_t = 0x15
236                                      criticality_t = 0
237                                      GlobalENB-ID
238                                       pLMN_Identity_t = 02 f8 29
239                                       eNB_ID_t:
240                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
241                                     ProtocolIE_Container_elm
242                                      id_t = 0x14
243                                      criticality_t = 0
244                                      ServedCells:
245                                       ServedCells_elm
246                                        servedCellInfo_t
247                                         pCI_t = 0x63
248                                         cellId_t
249                                          pLMN_Identity_t = 02 f8 29
250                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
251                                         tAC_t = 01 02
252                                         broadcastPLMNs_t:
253                                          BroadcastPLMNs_Item_elm = 02 f8 29
254                                         eUTRA_Mode_Info_t:
255                                          tDD_t
256                                           eARFCN_t = 0x1
257                                           transmission_Bandwidth_t = 0x3
258                                           subframeAssignment_t = 0x2
259                                           specialSubframe_Info_t
260                                            specialSubframePatterns_t = 0x4
261                                            cyclicPrefixDL_t = 0
262                                            cyclicPrefixUL_t = 0x1
263                         */
264                         packedPdu: "2006002a000002001500080002f82900007a8000140017000000630002f8290007ab50102002f829400001320820"},
265                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
266                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<tdd:<ear_fcn:1 transmission_bandwidth:BW50 subframe_assignment:SA2 special_subframe_info:<special_subframe_patterns:SSP4 cyclic_prefix_dl:EXTENDED cyclic_prefix_ul:NORMAL > additional_special_subframe_info:<additional_special_subframe_patterns:SSP9 cyclic_prefix_dl:NORMAL cyclic_prefix_ul:EXTENDED > > > eutra_mode:TDD ] []",
267                         /*
268                                 X2AP-PDU:
269                                  successfulOutcome_t
270                                   procedureCode_t = 0x6
271                                   criticality_t = 0
272                                   X2SetupResponse
273                                    protocolIEs_t:
274                                     ProtocolIE_Container_elm
275                                      id_t = 0x15
276                                      criticality_t = 0
277                                      GlobalENB-ID
278                                       pLMN_Identity_t = 02 f8 29
279                                       eNB_ID_t:
280                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
281                                     ProtocolIE_Container_elm
282                                      id_t = 0x14
283                                      criticality_t = 0
284                                      ServedCells:
285                                       ServedCells_elm
286                                        servedCellInfo_t
287                                         pCI_t = 0x63
288                                         cellId_t
289                                          pLMN_Identity_t = 02 f8 29
290                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
291                                         tAC_t = 01 02
292                                         broadcastPLMNs_t:
293                                          BroadcastPLMNs_Item_elm = 02 f8 29
294                                         eUTRA_Mode_Info_t:
295                                          tDD_t
296                                           eARFCN_t = 0x1
297                                           transmission_Bandwidth_t = 0x3
298                                           subframeAssignment_t = 0x2
299                                           specialSubframe_Info_t
300                                            specialSubframePatterns_t = 0x4
301                                            cyclicPrefixDL_t = 0x1
302                                            cyclicPrefixUL_t = 0
303                                           iE_Extensions_t:
304                                            ProtocolExtensionContainer_elm
305                                             id_t = 0x61
306                                             criticality_t = 0x1
307                                             AdditionalSpecialSubframe-Info
308                                              additionalspecialSubframePatterns_t = 0x9
309                                              cyclicPrefixDL_t = 0
310                                              cyclicPrefixUL_t = 0x1
311                         */
312                         packedPdu: "20060032000002001500080002f82900007a800014001f000000630002f8290007ab50102002f8295000013208800000006140021220"},
313
314                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
315                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<tdd:<ear_fcn:2 transmission_bandwidth:BW50 subframe_assignment:SA2 special_subframe_info:<special_subframe_patterns:SSP4 cyclic_prefix_dl:EXTENDED cyclic_prefix_ul:NORMAL > > > eutra_mode:TDD ] []",
316                         /*
317                                 X2AP-PDU:
318                                  successfulOutcome_t
319                                   procedureCode_t = 0x6
320                                   criticality_t = 0
321                                   X2SetupResponse
322                                    protocolIEs_t:
323                                     ProtocolIE_Container_elm
324                                      id_t = 0x15
325                                      criticality_t = 0
326                                      GlobalENB-ID
327                                       pLMN_Identity_t = 02 f8 29
328                                       eNB_ID_t:
329                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
330                                     ProtocolIE_Container_elm
331                                      id_t = 0x14
332                                      criticality_t = 0
333                                      ServedCells:
334                                       ServedCells_elm
335                                        servedCellInfo_t
336                                         pCI_t = 0x63
337                                         cellId_t
338                                          pLMN_Identity_t = 02 f8 29
339                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
340                                         tAC_t = 01 02
341                                         broadcastPLMNs_t:
342                                          BroadcastPLMNs_Item_elm = 02 f8 29
343                                         eUTRA_Mode_Info_t:
344                                          tDD_t
345                                           eARFCN_t = 0x1
346                                           transmission_Bandwidth_t = 0x3
347                                           subframeAssignment_t = 0x2
348                                           specialSubframe_Info_t
349                                            specialSubframePatterns_t = 0x4
350                                            cyclicPrefixDL_t = 0x1
351                                            cyclicPrefixUL_t = 0
352                                           iE_Extensions_t:
353                                            ProtocolExtensionContainer_elm
354                                             id_t = 0x5e
355                                             criticality_t = 0
356                                             EARFCNExtension = 0x2
357                         */
358                         packedPdu: "20060033000002001500080002f82900007a8000140020000000630002f8290007ab50102002f8295000013208800000005e0003800102"},
359
360                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
361                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<tdd:<ear_fcn:1 transmission_bandwidth:BW50 subframe_assignment:SA2 special_subframe_info:<special_subframe_patterns:SSP4 cyclic_prefix_dl:EXTENDED cyclic_prefix_ul:NORMAL > additional_special_subframe_extension_info:<additional_special_subframe_patterns_extension:SSP10 cyclic_prefix_dl:NORMAL cyclic_prefix_ul:NORMAL > > > eutra_mode:TDD ] []",
362                         /*
363                                 X2AP-PDU:
364                                  successfulOutcome_t
365                                   procedureCode_t = 0x6
366                                   criticality_t = 0
367                                   X2SetupResponse
368                                    protocolIEs_t:
369                                     ProtocolIE_Container_elm
370                                      id_t = 0x15
371                                      criticality_t = 0
372                                      GlobalENB-ID
373                                       pLMN_Identity_t = 02 f8 29
374                                       eNB_ID_t:
375                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
376                                     ProtocolIE_Container_elm
377                                      id_t = 0x14
378                                      criticality_t = 0
379                                      ServedCells:
380                                       ServedCells_elm
381                                        servedCellInfo_t
382                                         pCI_t = 0x63
383                                         cellId_t
384                                          pLMN_Identity_t = 02 f8 29
385                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
386                                         tAC_t = 01 02
387                                         broadcastPLMNs_t:
388                                          BroadcastPLMNs_Item_elm = 02 f8 29
389                                         eUTRA_Mode_Info_t:
390                                          tDD_t
391                                           eARFCN_t = 0x1
392                                           transmission_Bandwidth_t = 0x3
393                                           subframeAssignment_t = 0x2
394                                           specialSubframe_Info_t
395                                            specialSubframePatterns_t = 0x4
396                                            cyclicPrefixDL_t = 0x1
397                                            cyclicPrefixUL_t = 0
398                                           iE_Extensions_t:
399                                            ProtocolExtensionContainer_elm
400                                             id_t = 0xb3
401                                             criticality_t = 0x1
402                                             AdditionalSpecialSubframeExtension-Info
403                                              additionalspecialSubframePatternsExtension_t = 0
404                                              cyclicPrefixDL_t = 0
405                                              cyclicPrefixUL_t = 0
406                         */
407                         packedPdu: "20060031000002001500080002f82900007a800014001e000000630002f8290007ab50102002f829500001320880000000b3400100"},
408
409                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
410                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<tdd:<ear_fcn:2 transmission_bandwidth:BW50 subframe_assignment:SA2 special_subframe_info:<special_subframe_patterns:SSP4 cyclic_prefix_dl:EXTENDED cyclic_prefix_ul:NORMAL > additional_special_subframe_info:<additional_special_subframe_patterns:SSP9 cyclic_prefix_dl:NORMAL cyclic_prefix_ul:EXTENDED > additional_special_subframe_extension_info:<additional_special_subframe_patterns_extension:SSP10 cyclic_prefix_dl:NORMAL cyclic_prefix_ul:NORMAL > > > eutra_mode:TDD ] []",
411                         /*
412                                 X2AP-PDU:
413                                  successfulOutcome_t
414                                   procedureCode_t = 0x6
415                                   criticality_t = 0
416                                   X2SetupResponse
417                                    protocolIEs_t:
418                                     ProtocolIE_Container_elm
419                                      id_t = 0x15
420                                      criticality_t = 0
421                                      GlobalENB-ID
422                                       pLMN_Identity_t = 02 f8 29
423                                       eNB_ID_t:
424                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
425                                     ProtocolIE_Container_elm
426                                      id_t = 0x14
427                                      criticality_t = 0
428                                      ServedCells:
429                                       ServedCells_elm
430                                        servedCellInfo_t
431                                         pCI_t = 0x63
432                                         cellId_t
433                                          pLMN_Identity_t = 02 f8 29
434                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
435                                         tAC_t = 01 02
436                                         broadcastPLMNs_t:
437                                          BroadcastPLMNs_Item_elm = 02 f8 29
438                                         eUTRA_Mode_Info_t:
439                                          tDD_t
440                                           eARFCN_t = 0x1
441                                           transmission_Bandwidth_t = 0x3
442                                           subframeAssignment_t = 0x2
443                                           specialSubframe_Info_t
444                                            specialSubframePatterns_t = 0x4
445                                            cyclicPrefixDL_t = 0x1
446                                            cyclicPrefixUL_t = 0
447                                           iE_Extensions_t:
448                                            ProtocolExtensionContainer_elm
449                                             id_t = 0xb3
450                                             criticality_t = 0x1
451                                             AdditionalSpecialSubframeExtension-Info
452                                              additionalspecialSubframePatternsExtension_t = 0
453                                              cyclicPrefixDL_t = 0
454                                              cyclicPrefixUL_t = 0
455                                            ProtocolExtensionContainer_elm
456                                             id_t = 0x61
457                                             criticality_t = 0x1
458                                             AdditionalSpecialSubframe-Info
459                                              additionalspecialSubframePatterns_t = 0x9
460                                              cyclicPrefixDL_t = 0
461                                              cyclicPrefixUL_t = 0x1
462                                            ProtocolExtensionContainer_elm
463                                             id_t = 0x5e
464                                             criticality_t = 0
465                                             EARFCNExtension = 0x2
466
467                         */
468                         packedPdu: "2006003e000002001500080002f82900007a800014002b000000630002f8290007ab50102002f829500001320880000200b3400100006140021220005e0003800102"},
469
470                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80b0"},
471                         enb: "CONNECTED HOME_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD number_of_antenna_ports:AN1  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD ] []",
472                         /*
473                                 X2AP-PDU:
474                                  successfulOutcome_t
475                                   procedureCode_t = 0x6
476                                   criticality_t = 0
477                                   X2SetupResponse
478                                    protocolIEs_t:
479                                     ProtocolIE_Container_elm
480                                      id_t = 0x15
481                                      criticality_t = 0
482                                      GlobalENB-ID
483                                       pLMN_Identity_t = 02 f8 29
484                                       eNB_ID_t:
485                                        home_eNB_ID_t = 00 7a 80 b0 (28 bits)
486                                     ProtocolIE_Container_elm
487                                      id_t = 0x14
488                                      criticality_t = 0
489                                      ServedCells:
490                                       ServedCells_elm
491                                        servedCellInfo_t
492                                         pCI_t = 0x63
493                                         cellId_t
494                                          pLMN_Identity_t = 02 f8 29
495                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
496                                         tAC_t = 01 02
497                                         broadcastPLMNs_t:
498                                          BroadcastPLMNs_Item_elm = 02 f8 29
499                                         eUTRA_Mode_Info_t:
500                                          fDD_t
501                                           uL_EARFCN_t = 0x1
502                                           dL_EARFCN_t = 0x1
503                                           uL_Transmission_Bandwidth_t = 0x3
504                                           dL_Transmission_Bandwidth_t = 0x3
505                                         iE_Extensions_t:
506                                          ProtocolExtensionContainer_elm
507                                           id_t = 0x29
508                                           criticality_t = 0x1
509                                           Number-of-Antennaports = 0
510                                       ServedCells_elm
511                                        servedCellInfo_t
512                                         pCI_t = 0x64
513                                         cellId_t
514                                          pLMN_Identity_t = 02 f9 29
515                                          eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
516                                         tAC_t = 02 03
517                                         broadcastPLMNs_t:
518                                          BroadcastPLMNs_Item_elm = 02 f8 29
519                                          BroadcastPLMNs_Item_elm = 02 f9 29
520                                         eUTRA_Mode_Info_t:nb_id
521                                          fDD_t
522                                           uL_EARFCN_t = 0x2
523                                           dL_EARFCN_t = 0x3
524                                           uL_Transmission_Bandwidth_t = 0x4
525                                           dL_Transmission_Bandwidth_t = 0x4
526
527                         */
528                         packedPdu: "2006004b000002001500090002f82940007a80b000140037010800630002f8290007ab50102002f829000001000133000000294001000000640002f9290007ac50203202f82902f929000002000344"},
529
530                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a40"},
531                         enb: "CONNECTED SHORT_MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD number_of_antenna_ports:AN1  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD prach_configuration:<root_sequence_index:15 zero_correlation_zone_configuration:7 high_speed_flag:true prach_frequency_offset:30 > ] []",
532                         /*
533                                 X2AP-PDU:
534                                  successfulOutcome_t
535                                   procedureCode_t = 0x6
536                                   criticality_t = 0
537                                   X2SetupResponse
538                                    protocolIEs_t:
539                                         ProtocolIE_Container_elm
540                                          id_t = 0x15
541                                          criticality_t = 0
542                                          GlobalENB-ID
543                                           pLMN_Identity_t = 02 f8 29
544                                           eNB_ID_t:
545                                            short_Macro_eNB_ID_t = 00 7a 40 (18 bits)
546                                         ProtocolIE_Container_elm
547                                          id_t = 0x14
548                                          criticality_t = 0
549                                          ServedCells:
550                                           ServedCells_elm
551                                            servedCellInfo_t
552                                                 pCI_t = 0x63
553                                                 cellId_t
554                                                  pLMN_Identity_t = 02 f8 29
555                                                  eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
556                                                 tAC_t = 01 02
557                                                 broadcastPLMNs_t:
558                                                  BroadcastPLMNs_Item_elm = 02 f8 29
559                                                 eUTRA_Mode_Info_t:
560                                                  fDD_t
561                                                   uL_EARFCN_t = 0x1
562                                                   dL_EARFCN_t = 0x1
563                                                   uL_Transmission_Bandwidth_t = 0x3
564                                                   dL_Transmission_Bandwidth_t = 0x3
565                                                 iE_Extensions_t:
566                                                  ProtocolExtensionContainer_elm
567                                                   id_t = 0x29
568                                                   criticality_t = 0x1
569                                                   Number-of-Antennaports = 0
570                                           ServedCells_elm
571                                            servedCellInfo_t
572                                                 pCI_t = 0x64
573                                                 cellId_t
574                                                  pLMN_Identity_t = 02 f9 29
575                                                  eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
576                                                 tAC_t = 02 03
577                                                 broadcastPLMNs_t:
578                                                  BroadcastPLMNs_Item_elm = 02 f8 29
579                                                  BroadcastPLMNs_Item_elm = 02 f9 29
580                                                 eUTRA_Mode_Info_t:
581                                                  fDD_t
582                                                   uL_EARFCN_t = 0x2
583                                                   dL_EARFCN_t = 0x3
584                                                   uL_Transmission_Bandwidth_t = 0x4
585                                                   dL_Transmission_Bandwidth_t = 0x4
586                                                 iE_Extensions_t:
587                                                  ProtocolExtensionContainer_elm
588                                                   id_t = 0x37
589                                                   criticality_t = 0x1
590                                                   PRACH-Configuration
591                                                    rootSequenceIndex_t = 0xf
592                                                    zeroCorrelationIndex_t = 0x7
593                                                    highSpeedFlag_t = true
594                                                    prach_FreqOffset_t = 0x1e
595
596                         */
597                         packedPdu: "20060056000002001500090002f8298003007a4000140042010800630002f8290007ab50102002f829000001000133000000294001000800640002f9290007ac50203202f82902f92900000200034400000037400500000f79e0"},
598
599                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a40"},
600                         enb: "CONNECTED SHORT_MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD number_of_antenna_ports:AN1  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD mbsfn_subframe_infos:<radioframe_allocation_period:N8 radioframe_allocation_offset:3 subframe_allocation:\"28\" subframe_allocation_type:ONE_FRAME > ] []",
601                         /*
602                                 X2AP-PDU:
603                                  successfulOutcome_t
604                                   procedureCode_t = 0x6
605                                   criticality_t = 0
606                                   X2SetupResponse
607                                    protocolIEs_t:
608                                         ProtocolIE_Container_elm
609                                          id_t = 0x15
610                                          criticality_t = 0
611                                          GlobalENB-ID
612                                           pLMN_Identity_t = 02 f8 29
613                                           eNB_ID_t:
614                                            short_Macro_eNB_ID_t = 00 7a 40 (18 bits)
615                                         ProtocolIE_Container_elm
616                                          id_t = 0x14
617                                          criticality_t = 0
618                                          ServedCells:
619                                           ServedCells_elm
620                                            servedCellInfo_t
621                                                 pCI_t = 0x63
622                                                 cellId_t
623                                                  pLMN_Identity_t = 02 f8 29
624                                                  eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
625                                                 tAC_t = 01 02
626                                                 broadcastPLMNs_t:
627                                                  BroadcastPLMNs_Item_elm = 02 f8 29
628                                                 eUTRA_Mode_Info_t:
629                                                  fDD_t
630                                                   uL_EARFCN_t = 0x1
631                                                   dL_EARFCN_t = 0x1
632                                                   uL_Transmission_Bandwidth_t = 0x3
633                                                   dL_Transmission_Bandwidth_t = 0x3
634                                                 iE_Extensions_t:
635                                                  ProtocolExtensionContainer_elm
636                                                   id_t = 0x29
637                                                   criticality_t = 0x1
638                                                   Number-of-Antennaports = 0
639                                           ServedCells_elm
640                                            servedCellInfo_t
641                                                 pCI_t = 0x64
642                                                 cellId_t
643                                                  pLMN_Identity_t = 02 f9 29
644                                                  eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
645                                                 tAC_t = 02 03
646                                                 broadcastPLMNs_t:
647                                                  BroadcastPLMNs_Item_elm = 02 f8 29
648                                                  BroadcastPLMNs_Item_elm = 02 f9 29
649                                                 eUTRA_Mode_Info_t:
650                                                  fDD_t
651                                                   uL_EARFCN_t = 0x2
652                                                   dL_EARFCN_t = 0x3
653                                                   uL_Transmission_Bandwidth_t = 0x4
654                                                   dL_Transmission_Bandwidth_t = 0x4
655                                                 iE_Extensions_t:
656                                                  ProtocolExtensionContainer_elm
657                                                   id_t = 0x38
658                                                   criticality_t = 0x1
659                                                   MBSFN-Subframe-Infolist:
660                                                    MBSFN_Subframe_Infolist_elm
661                                                         radioframeAllocationPeriod_t = 0x3
662                                                         radioframeAllocationOffset_t = 0x3
663                                                         subframeAllocation_t:
664                                                          oneframe_t = 28 (6 bits)
665                         */
666                         packedPdu: "20060054000002001500090002f8298003007a4000140040010800630002f8290007ab50102002f829000001000133000000294001000800640002f9290007ac50203202f82902f929000002000344000000384003019850"},
667                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a40"},
668                         enb: "CONNECTED SHORT_MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD number_of_antenna_ports:AN1 mbsfn_subframe_infos:<radioframe_allocation_period:N8 radioframe_allocation_offset:3 subframe_allocation:\"28\" subframe_allocation_type:ONE_FRAME >  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD ] []",
669                         /*
670                                 X2AP-PDU:
671                                  successfulOutcome_t
672                                   procedureCode_t = 0x6
673                                   criticality_t = 0
674                                   X2SetupResponse
675                                    protocolIEs_t:
676                                     ProtocolIE_Container_elm
677                                      id_t = 0x15
678                                      criticality_t = 0
679                                      GlobalENB-ID
680                                       pLMN_Identity_t = 02 f8 29
681                                       eNB_ID_t:
682                                        short_Macro_eNB_ID_t = 00 7a 40 (18 bits)
683                                     ProtocolIE_Container_elm
684                                      id_t = 0x14
685                                      criticality_t = 0
686                                      ServedCells:
687                                       ServedCells_elm
688                                        servedCellInfo_t
689                                         pCI_t = 0x63
690                                         cellId_t
691                                          pLMN_Identity_t = 02 f8 29
692                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
693                                         tAC_t = 01 02
694                                         broadcastPLMNs_t:
695                                          BroadcastPLMNs_Item_elm = 02 f8 29
696                                         eUTRA_Mode_Info_t:
697                                          fDD_t
698                                           uL_EARFCN_t = 0x1
699                                           dL_EARFCN_t = 0x1
700                                           uL_Transmission_Bandwidth_t = 0x3
701                                           dL_Transmission_Bandwidth_t = 0x3
702                                         iE_Extensions_t:
703                                          ProtocolExtensionContainer_elm
704                                           id_t = 0x29
705                                           criticality_t = 0x1
706                                           Number-of-Antennaports = 0
707                                          ProtocolExtensionContainer_elm
708                                           id_t = 0x38
709                                           criticality_t = 0x1
710                                           MBSFN-Subframe-Infolist:
711                                            MBSFN_Subframe_Infolist_elm
712                                             radioframeAllocationPeriod_t = 0x3
713                                             radioframeAllocationOffset_t = 0x3
714                                             subframeAllocation_t:
715                                              oneframe_t = 28 (6 bits)
716                                       ServedCells_elm
717                                        servedCellInfo_t
718                                         pCI_t = 0x64
719                                         cellId_t
720                                          pLMN_Identity_t = 02 f9 29
721                                          eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
722                                         tAC_t = 02 03
723                                         broadcastPLMNs_t:
724                                          BroadcastPLMNs_Item_elm = 02 f8 29
725                                          BroadcastPLMNs_Item_elm = 02 f9 29
726                                         eUTRA_Mode_Info_t:
727                                          fDD_t
728                                           uL_EARFCN_t = 0x2
729                                           dL_EARFCN_t = 0x3
730                                           uL_Transmission_Bandwidth_t = 0x4
731                                           dL_Transmission_Bandwidth_t = 0x4
732                         */
733                         packedPdu: "20060052000002001500090002f8298003007a400014003e010800630002f8290007ab50102002f82900000100013300010029400100003840030198500000640002f9290007ac50203202f82902f929000002000344"},
734                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a40"},
735                         enb: "CONNECTED SHORT_MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD number_of_antenna_ports:AN1 prach_configuration:<root_sequence_index:15 zero_correlation_zone_configuration:7 high_speed_flag:true prach_frequency_offset:30 >  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD ] []",
736                         /*
737                                 X2AP-PDU:
738                                  successfulOutcome_t
739                                   procedureCode_t = 0x6
740                                   criticality_t = 0
741                                   X2SetupResponse
742                                    protocolIEs_t:
743                                     ProtocolIE_Container_elm
744                                      id_t = 0x15
745                                      criticality_t = 0
746                                      GlobalENB-ID
747                                       pLMN_Identity_t = 02 f8 29
748                                       eNB_ID_t:
749                                        short_Macro_eNB_ID_t = 00 7a 40 (18 bits)
750                                     ProtocolIE_Container_elm
751                                      id_t = 0x14
752                                      criticality_t = 0
753                                      ServedCells:
754                                       ServedCells_elm
755                                        servedCellInfo_t
756                                         pCI_t = 0x63
757                                         cellId_t
758                                          pLMN_Identity_t = 02 f8 29
759                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
760                                         tAC_t = 01 02
761                                         broadcastPLMNs_t:
762                                          BroadcastPLMNs_Item_elm = 02 f8 29
763                                         eUTRA_Mode_Info_t:
764                                          fDD_t
765                                           uL_EARFCN_t = 0x1
766                                           dL_EARFCN_t = 0x1
767                                           uL_Transmission_Bandwidth_t = 0x3
768                                           dL_Transmission_Bandwidth_t = 0x3
769                                         iE_Extensions_t:
770                                          ProtocolExtensionContainer_elm
771                                           id_t = 0x29
772                                           criticality_t = 0x1
773                                           Number-of-Antennaports = 0
774                                          ProtocolExtensionContainer_elm
775                                           id_t = 0x37
776                                           criticality_t = 0x1
777                                           PRACH-Configuration
778                                            rootSequenceIndex_t = 0xf
779                                            zeroCorrelationIndex_t = 0x7
780                                            highSpeedFlag_t = true
781                                            prach_FreqOffset_t = 0x1e
782                                       ServedCells_elm
783                                        servedCellInfo_t
784                                         pCI_t = 0x64
785                                         cellId_t
786                                          pLMN_Identity_t = 02 f9 29
787                                          eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
788                                         tAC_t = 02 03
789                                         broadcastPLMNs_t:
790                                          BroadcastPLMNs_Item_elm = 02 f8 29
791                                          BroadcastPLMNs_Item_elm = 02 f9 29
792                                         eUTRA_Mode_Info_t:
793                                          fDD_t
794                                           uL_EARFCN_t = 0x2
795                                           dL_EARFCN_t = 0x3
796                                           uL_Transmission_Bandwidth_t = 0x4
797                                           dL_Transmission_Bandwidth_t = 0x4
798                         */
799                         packedPdu: "20060054000002001500090002f8298003007a4000140040010800630002f8290007ab50102002f829000001000133000100294001000037400500000f79e00000640002f9290007ac50203202f82902f929000002000344"},
800                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a08"},
801                         enb: "CONNECTED LONG_MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD prach_configuration:<root_sequence_index:15 zero_correlation_zone_configuration:7 high_speed_flag:true prach_frequency_offset:30 prach_configuration_index:60 >  pci:100 cell_id:\"02f929:0007ac50\" tac:\"0203\" broadcast_plmns:\"02f829\" broadcast_plmns:\"02f929\" choice_eutra_mode:<fdd:<ulear_fcn:2 dlear_fcn:3 ul_transmission_bandwidth:BW75 dl_transmission_bandwidth:BW75 > > eutra_mode:FDD ] []",
802                         /*
803                                 X2AP-PDU:
804                                  successfulOutcome_t
805                                   procedureCode_t = 0x6
806                                   criticality_t = 0
807                                   X2SetupResponse
808                                    protocolIEs_t:
809                                         ProtocolIE_Container_elm
810                                          id_t = 0x15
811                                          criticality_t = 0
812                                          GlobalENB-ID
813                                           pLMN_Identity_t = 02 f8 29
814                                           eNB_ID_t:
815                                            long_Macro_eNB_ID_t = 00 7a 08 (21 bits)
816                                         ProtocolIE_Container_elm
817                                          id_t = 0x14
818                                          criticality_t = 0
819                                          ServedCells:
820                                           ServedCells_elm
821                                            servedCellInfo_t
822                                                 pCI_t = 0x63
823                                                 cellId_t
824                                                  pLMN_Identity_t = 02 f8 29
825                                                  eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
826                                                 tAC_t = 01 02
827                                                 broadcastPLMNs_t:
828                                                  BroadcastPLMNs_Item_elm = 02 f8 29
829                                                 eUTRA_Mode_Info_t:
830                                                  fDD_t
831                                                   uL_EARFCN_t = 0x1
832                                                   dL_EARFCN_t = 0x1
833                                                   uL_Transmission_Bandwidth_t = 0x3
834                                                   dL_Transmission_Bandwidth_t = 0x3
835                                                 iE_Extensions_t:
836                                                  ProtocolExtensionContainer_elm
837                                                   id_t = 0x37
838                                                   criticality_t = 0x1
839                                                   PRACH-Configuration
840                                                    rootSequenceIndex_t = 0xf
841                                                    zeroCorrelationIndex_t = 0x7
842                                                    highSpeedFlag_t = true
843                                                    prach_FreqOffset_t = 0x1e
844                                                    prach_ConfigIndex_t = 0x3c
845                                           ServedCells_elm
846                                            servedCellInfo_t
847                                                 pCI_t = 0x64
848                                                 cellId_t
849                                                  pLMN_Identity_t = 02 f9 29
850                                                  eUTRANcellIdentifier_t = 00 07 ac 50 (28 bits)
851                                                 tAC_t = 02 03
852                                                 broadcastPLMNs_t:
853                                                  BroadcastPLMNs_Item_elm = 02 f8 29
854                                                  BroadcastPLMNs_Item_elm = 02 f9 29
855                                                 eUTRA_Mode_Info_t:
856                                                  fDD_t
857                                                   uL_EARFCN_t = 0x2
858                                                   dL_EARFCN_t = 0x3
859                                                   uL_Transmission_Bandwidth_t = 0x4
860                                                   dL_Transmission_Bandwidth_t = 0x4
861                         */
862                         //packedPdu: "20060050000002001500090002f8298103007a080014003c010800630002f8290007ab50102002f82900000100013300000037400640000f79ef000000640002f9290007ac50203202f82902f929000002000344"},
863                         packedPdu: "20060050000002001500090002f829c003007a080014003c010800630002f8290007ab50102002f82900000100013300000037400640000f79ef000000640002f9290007ac50203202f82902f929000002000344"},
864
865                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
866                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD csg_id:\"0007aba0\" freq_band_indicator_priority:BROADCASTED bandwidth_reduced_si:SCHEDULED ] []",
867                         /*
868                                 X2AP-PDU:
869                                  successfulOutcome_t
870                                   procedureCode_t = 0x6
871                                   criticality_t = 0
872                                   X2SetupResponse
873                                    protocolIEs_t:
874                                     ProtocolIE_Container_elm
875                                      id_t = 0x15
876                                      criticality_t = 0
877                                      GlobalENB-ID
878                                       pLMN_Identity_t = 02 f8 29
879                                       eNB_ID_t:
880                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
881                                     ProtocolIE_Container_elm
882                                      id_t = 0x14
883                                      criticality_t = 0
884                                      ServedCells:
885                                       ServedCells_elm
886                                        servedCellInfo_t
887                                         pCI_t = 0x63
888                                         cellId_t
889                                          pLMN_Identity_t = 02 f8 29
890                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
891                                         tAC_t = 01 02
892                                         broadcastPLMNs_t:
893                                          BroadcastPLMNs_Item_elm = 02 f8 29
894                                         eUTRA_Mode_Info_t:
895                                          fDD_t
896                                           uL_EARFCN_t = 0x1
897                                           dL_EARFCN_t = 0x1
898                                           uL_Transmission_Bandwidth_t = 0x3
899                                           dL_Transmission_Bandwidth_t = 0x3
900                                         iE_Extensions_t:
901                                          ProtocolExtensionContainer_elm
902                                           id_t = 0x46
903                                           criticality_t = 0x1
904                                           CSG-Id = 00 07 ab a0 (27 bits)
905                                          ProtocolExtensionContainer_elm
906                                           id_t = 0xa0
907                                           criticality_t = 0x1
908                                           FreqBandIndicatorPriority = 0x1
909                                          ProtocolExtensionContainer_elm
910                                           id_t = 0xb4
911                                           criticality_t = 0x1
912                                           BandwidthReducedSI = 0
913                         */
914                         packedPdu: "2006003e000002001500080002f82900007a800014002b000800630002f8290007ab50102002f8290000010001330002004640040007aba000a040014000b4400100"},
915
916                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
917                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD mbms_service_area_identities:\"02f8\" mbms_service_area_identities:\"03f9\" multiband_infos:1 multiband_infos:2 multiband_infos:3 freq_band_indicator_priority:NOT_BROADCASTED ] []",
918                         /*
919                                 X2AP-PDU:
920                                  successfulOutcome_t
921                                   procedureCode_t = 0x6
922                                   criticality_t = 0
923                                   X2SetupResponse
924                                    protocolIEs_t:
925                                     ProtocolIE_Container_elm
926                                      id_t = 0x15
927                                      criticality_t = 0
928                                      GlobalENB-ID
929                                       pLMN_Identity_t = 02 f8 29
930                                       eNB_ID_t:
931                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
932                                     ProtocolIE_Container_elm
933                                      id_t = 0x14
934                                      criticality_t = 0
935                                      ServedCells:
936                                       ServedCells_elm
937                                        servedCellInfo_t
938                                         pCI_t = 0x63
939                                         cellId_t
940                                          pLMN_Identity_t = 02 f8 29
941                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
942                                         tAC_t = 01 02
943                                         broadcastPLMNs_t:
944                                          BroadcastPLMNs_Item_elm = 02 f8 29
945                                         eUTRA_Mode_Info_t:
946                                          fDD_t
947                                           uL_EARFCN_t = 0x1
948                                           dL_EARFCN_t = 0x1
949                                           uL_Transmission_Bandwidth_t = 0x3
950                                           dL_Transmission_Bandwidth_t = 0x3
951                                         iE_Extensions_t:
952                                          ProtocolExtensionContainer_elm
953                                           id_t = 0x4f
954                                           criticality_t = 0x1
955                                           MBMS-Service-Area-Identity-List:
956                                            MBMS_Service_Area_Identity_List_elm = 02 f8
957                                            MBMS_Service_Area_Identity_List_elm = 03 f9
958                                          ProtocolExtensionContainer_elm
959                                           id_t = 0xa0
960                                           criticality_t = 0x1
961                                           FreqBandIndicatorPriority = 0
962                                          ProtocolExtensionContainer_elm
963                                           id_t = 0x54
964                                           criticality_t = 0x1
965                                           MultibandInfoList:
966                                            MultibandInfoList_elm
967                                             freqBandIndicator_t = 0x1
968                                            MultibandInfoList_elm
969                                             freqBandIndicator_t = 0x2
970                                            MultibandInfoList_elm
971                                             freqBandIndicator_t = 0x3
972                         */
973                         packedPdu: "20060044000002001500080002f82900007a8000140031000800630002f8290007ab50102002f8290000010001330002004f40050102f803f900a040010000544006200000010002"},
974                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
975                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD neighbour_infos:<ecgi:\"02f829:0007ab50\" pci:99 ear_fcn:1 > neighbour_infos:<ecgi:\"03f930:0008bc50\" pci:100 ear_fcn:2 > ] []",
976                         /*
977                                 X2AP-PDU:
978                                  successfulOutcome_t
979                                   procedureCode_t = 0x6
980                                   criticality_t = 0
981                                   X2SetupResponse
982                                    protocolIEs_t:
983                                     ProtocolIE_Container_elm
984                                      id_t = 0x15
985                                      criticality_t = 0
986                                      GlobalENB-ID
987                                       pLMN_Identity_t = 02 f8 29
988                                       eNB_ID_t:
989                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
990                                     ProtocolIE_Container_elm
991                                      id_t = 0x14
992                                      criticality_t = 0
993                                      ServedCells:
994                                       ServedCells_elm
995                                        servedCellInfo_t
996                                         pCI_t = 0x63
997                                         cellId_t
998                                          pLMN_Identity_t = 02 f8 29
999                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
1000                                         tAC_t = 01 02
1001                                         broadcastPLMNs_t:
1002                                          BroadcastPLMNs_Item_elm = 02 f8 29
1003                                         eUTRA_Mode_Info_t:
1004                                          fDD_t
1005                                           uL_EARFCN_t = 0x1
1006                                           dL_EARFCN_t = 0x1
1007                                           uL_Transmission_Bandwidth_t = 0x3
1008                                           dL_Transmission_Bandwidth_t = 0x3
1009                                        neighbour_Info_t:
1010                                         Neighbour_Information_elm
1011                                          eCGI_t
1012                                           pLMN_Identity_t = 02 f8 29
1013                                           eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
1014                                          pCI_t = 0x63
1015                                          eARFCN_t = 0x1
1016                                         Neighbour_Information_elm
1017                                          eCGI_t
1018                                           pLMN_Identity_t = 03 f9 30
1019                                           eUTRANcellIdentifier_t = 00 08 bc 50 (28 bits)
1020                                          pCI_t = 0x64
1021                                          eARFCN_t = 0x2
1022                         */
1023                         packedPdu: "20060044000002001500080002f82900007a8000140031004000630002f8290007ab50102002f82900000100013300020002f8290007ab50006300010003f9300008bc5000640002"},
1024
1025                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
1026                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD neighbour_infos:<ecgi:\"02f829:0007ab50\" pci:99 ear_fcn:1 tac:\"0102\" > neighbour_infos:<ecgi:\"03f930:0008bc50\" pci:100 ear_fcn:3 > ] []",
1027                         /*
1028                                 X2AP-PDU:
1029                                  successfulOutcome_t
1030                                   procedureCode_t = 0x6
1031                                   criticality_t = 0
1032                                   X2SetupResponse
1033                                    protocolIEs_t:
1034                                     ProtocolIE_Container_elm
1035                                      id_t = 0x15
1036                                      criticality_t = 0
1037                                      GlobalENB-ID
1038                                       pLMN_Identity_t = 02 f8 29
1039                                       eNB_ID_t:
1040                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
1041                                     ProtocolIE_Container_elm
1042                                      id_t = 0x14
1043                                      criticality_t = 0
1044                                      ServedCells:
1045                                       ServedCells_elm
1046                                        servedCellInfo_t
1047                                         pCI_t = 0x63
1048                                         cellId_t
1049                                          pLMN_Identity_t = 02 f8 29
1050                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
1051                                         tAC_t = 01 02
1052                                         broadcastPLMNs_t:
1053                                          BroadcastPLMNs_Item_elm = 02 f8 29
1054                                         eUTRA_Mode_Info_t:
1055                                          fDD_t
1056                                           uL_EARFCN_t = 0x1
1057                                           dL_EARFCN_t = 0x1
1058                                           uL_Transmission_Bandwidth_t = 0x3
1059                                           dL_Transmission_Bandwidth_t = 0x3
1060                                        neighbour_Info_t:
1061                                         Neighbour_Information_elm
1062                                          eCGI_t
1063                                           pLMN_Identity_t = 02 f8 29
1064                                           eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
1065                                          pCI_t = 0x63
1066                                          eARFCN_t = 0x1
1067                                          iE_Extensions_t:
1068                                           ProtocolExtensionContainer_elm
1069                                            id_t = 0x4c
1070                                            criticality_t = 0x1
1071                                            TAC = 01 02
1072                                         Neighbour_Information_elm
1073                                          eCGI_t
1074                                           pLMN_Identity_t = 03 f9 30
1075                                           eUTRANcellIdentifier_t = 00 08 bc 50 (28 bits)
1076                                          pCI_t = 0x64
1077                                          eARFCN_t = 0x2
1078                                          iE_Extensions_t:
1079                                           ProtocolExtensionContainer_elm
1080                                            id_t = 0x5e
1081                                            criticality_t = 0
1082                                            EARFCNExtension = 0x3
1083                         */
1084                         packedPdu: "20060055000002001500080002f82900007a8000140042004000630002f8290007ab50102002f82900000100013300024002f8290007ab50006300010000004c400201024003f9300008bc50006400020000005e0003800103"},
1085
1086                 {key: &entities.GlobalNbId{PlmnId: "02f829", NbId: "007a80"},
1087                         enb: "CONNECTED MACRO_ENB [pci:99 cell_id:\"02f829:0007ab50\" tac:\"0102\" broadcast_plmns:\"02f829\" choice_eutra_mode:<fdd:<ulear_fcn:1 dlear_fcn:1 ul_transmission_bandwidth:BW50 dl_transmission_bandwidth:BW50 > > eutra_mode:FDD neighbour_infos:<ecgi:\"02f829:0007ab50\" pci:99 ear_fcn:1 tac:\"0102\" > neighbour_infos:<ecgi:\"03f930:0008bc50\" pci:100 ear_fcn:3 > ] []",
1088                         /*
1089                                 X2AP-PDU:
1090                                  successfulOutcome_t
1091                                   procedureCode_t = 0x6
1092                                   criticality_t = 0
1093                                   X2SetupResponse
1094                                    protocolIEs_t:
1095                                     ProtocolIE_Container_elm
1096                                      id_t = 0x15
1097                                      criticality_t = 0
1098                                      GlobalENB-ID
1099                                       pLMN_Identity_t = 02 f8 29
1100                                       eNB_ID_t:
1101                                        macro_eNB_ID_t = 00 7a 80 (20 bits)
1102                                     ProtocolIE_Container_elm
1103                                      id_t = 0x14
1104                                      criticality_t = 0
1105                                      ServedCells:
1106                                       ServedCells_elm
1107                                        servedCellInfo_t
1108                                         pCI_t = 0x63
1109                                         cellId_t
1110                                          pLMN_Identity_t = 02 f8 29
1111                                          eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
1112                                         tAC_t = 01 02
1113                                         broadcastPLMNs_t:
1114                                          BroadcastPLMNs_Item_elm = 02 f8 29
1115                                         eUTRA_Mode_Info_t:
1116                                          fDD_t
1117                                           uL_EARFCN_t = 0x1
1118                                           dL_EARFCN_t = 0x1
1119                                           uL_Transmission_Bandwidth_t = 0x3
1120                                           dL_Transmission_Bandwidth_t = 0x3
1121                                        neighbour_Info_t:
1122                                         Neighbour_Information_elm
1123                                          eCGI_t
1124                                           pLMN_Identity_t = 02 f8 29
1125                                           eUTRANcellIdentifier_t = 00 07 ab 50 (28 bits)
1126                                          pCI_t = 0x63
1127                                          eARFCN_t = 0x1
1128                                          iE_Extensions_t:
1129                                           ProtocolExtensionContainer_elm
1130                                            id_t = 0x4c
1131                                            criticality_t = 0x1
1132                                            TAC = 01 02
1133                                         Neighbour_Information_elm
1134                                          eCGI_t
1135                                           pLMN_Identity_t = 03 f9 30
1136                                           eUTRANcellIdentifier_t = 00 08 bc 50 (28 bits)
1137                                          pCI_t = 0x64
1138                                          eARFCN_t = 0x2
1139                                          iE_Extensions_t:
1140                                           ProtocolExtensionContainer_elm
1141                                            id_t = 0x5e
1142                                            criticality_t = 0
1143                                            EARFCNExtension = 0x3
1144                         */
1145                         packedPdu: "20060055000002001500080002f82900007a8000140042004000630002f8290007ab50102002f82900000100013300024002f8290007ab50006300010000004c400201024003f9300008bc50006400020000005e0003800103",
1146                         /*failure: fmt.Errorf("getAtom for path [successfulOutcome_t X2SetupResponse protocolIEs_t ProtocolIE_Container_elm GlobalENB-ID pLMN_Identity_t] failed, rc = 2" /NO_SPACE_LEFT),*/ },
1147         }
1148
1149         for _, tc := range testCases {
1150                 t.Run(tc.packedPdu, func(t *testing.T) {
1151
1152                         var payload []byte
1153                         _, err := fmt.Sscanf(tc.packedPdu, "%x", &payload)
1154                         if err != nil {
1155                                 t.Errorf("convert inputPayloadAsStr to payloadAsByte. Error: %v\n", err)
1156                         }
1157
1158                         key, enb, err := UnpackX2SetupResponseAndExtract(logger, e2pdus.MaxAsn1CodecAllocationBufferSize, len(payload), payload, e2pdus.MaxAsn1CodecMessageBufferSize /*message buffer*/)
1159
1160                         if err != nil {
1161                                 if tc.failure == nil {
1162                                         t.Errorf("want: success, got: error: %v\n", err)
1163                                 } else {
1164                                         if strings.Compare(err.Error(), tc.failure.Error()) != 0 {
1165                                                 t.Errorf("want: %s, got: %s", tc.failure, err)
1166                                         }
1167                                 }
1168                         }
1169
1170                         if key == nil {
1171                                 if tc.failure == nil {
1172                                         t.Errorf("want: key=%v, got: empty key", tc.key)
1173                                 }
1174                         } else {
1175                                 if strings.Compare(key.PlmnId, tc.key.PlmnId) != 0 || strings.Compare(key.NbId, tc.key.NbId) != 0 {
1176                                         t.Errorf("want: key=%s, got: %s", tc.key, key)
1177                                 }
1178                         }
1179
1180                         if enb == nil {
1181                                 if tc.failure == nil {
1182                                         t.Errorf("want: enb=%s, got: empty enb", tc.enb)
1183                                 }
1184                         } else {
1185                                 nb := &entities.NodebInfo{}
1186                                 nb.ConnectionStatus = entities.ConnectionStatus_CONNECTED
1187                                 nb.Configuration = &entities.NodebInfo_Enb{Enb: enb}
1188                                 embStr := fmt.Sprintf("%s %s %s %s", nb.ConnectionStatus, enb.EnbType, enb.ServedCells, enb.GuGroupIds)
1189                                 if !strings.EqualFold(embStr, tc.enb) {
1190                                         t.Errorf("want: enb=%s, got: %s", tc.enb, embStr)
1191                                 }
1192                         }
1193                 })
1194         }
1195 }