K2InformaticsGmbH / smpp_parser

A parser for SMPP protocol PDUs
Apache License 2.0
3 stars 1 forks source link

smpp_test_utils:'-pack_unpack/1-fun-1-' failed on line 66 Reason: assertEqual: data_sm_resp #96

Closed walter-weinmann closed 6 years ago

walter-weinmann commented 6 years ago
Command: data_sm_resp
PDU: "00 00 00 53 80 00 01 03 00 00 00 00 00 00 00 01 74 68 69 73 5F 63 6F 75 6C 64 5F 62 65 5F 61 5F 6D 65 73 73 61 67 65 5F 69 64 00 00 1D 00 1F 6D 79 5F 61 64 64 69 74 69 6F 6E 61 6C 5F 73 74 61 74 75 73 5F 69 6E 66 6F 5F 74 65 78 74 00 04 20 00 01 00"

*** User 2018-05-31 05:19:14.308 ***
smpp_test_utils:pack_unpack:60 ===> data_sm_resp
#{additional_status_info_text => "my_additional_status_info_text",
  command_id => 2147483907,command_length => 83,command_status => 0,
  dpf_result => 0,message_id => "this_could_be_a_message_id",
  sequence_number => 1}
{
  "additional_status_info_text": "my_additional_status_info_text",
  "command_id": 2147483907,
  "command_length": 83,
  "command_status": 0,
  "dpf_result": 0,
  "message_id": "this_could_be_a_message_id",
  "sequence_number": 1
}

*** User 2018-05-31 05:19:14.309 ***
smpp_test_utils:pack_unpack:63 ===> 
Expected : <<0,0,0,83,128,0,1,3,0,0,0,0,0,0,0,1,116,104,105,115,95,99,111,117,
             108,100,95,98,101,95,97,95,109,101,115,115,97,103,101,95,105,100,
             0,0,29,0,31,109,121,95,97,100,100,105,116,105,111,110,97,108,95,
             115,116,97,116,117,115,95,105,110,102,111,95,116,101,120,116,0,4,
             32,0,1,0>>
Got      : <<0,0,0,83,128,0,1,3,0,0,0,0,0,0,0,1,116,104,105,115,95,99,111,117,
             108,100,95,98,101,95,97,95,109,101,115,115,97,103,101,95,105,100,
             0,4,32,0,1,0,0,29,0,31,109,121,95,97,100,100,105,116,105,111,110,
             97,108,95,115,116,97,116,117,115,95,105,110,102,111,95,116,101,
             120,116,0>>

00 00 00 53 # command_length
80 00 01 03 # command_id
00 00 00 00 # command_status
00 00 00 01 # sequence_number
74 68 69 73 5F 63 6F 75 6C 64 5F 62 65 5F 61 5F 6D 65 73 73 61 67 65 5F 69 64 00 # service_type
00 # source_addr_ton
1D # source_addr_npi
00 # source_addr
1F # dest_addr_ton
6D # dest_addr_npi
79 5F 61 64 64 69 74 69 6F 6E 61 6C 5F 73 74 61 74 75 73 5F 69 6E 66 6F 5F 74 65 78 74 00 # destination_addr
Message Submission TLV - dpf_result
04 20 
00 01 
00
c-bik commented 6 years ago

@walter-weinmann Unable to reproduce

walter-weinmann commented 6 years ago

Error with unpack_map_pack

*** User 2018-06-04 04:47:37.400 ***
smpp_test_utils:unpack_map_pack:54 ===> unbind
#{additional_status_info_text => "my_additional_status_info_text",
  command_id => 2147483907,command_length => 83,command_status => 0,
  dpf_result => 0,message_id => "this_could_be_a_message_id",
  sequence_number => 1}
{
  "additional_status_info_text": "my_additional_status_info_text",
  "command_id": 2147483907,
  "command_length": 83,
  "command_status": 0,
  "dpf_result": 0,
  "message_id": "this_could_be_a_message_id",
  "sequence_number": 1
}

*** User 2018-06-04 04:47:37.400 ***
smpp_test_utils:unpack_map_pack:57 ===> 
Expected : <<0,0,0,83,128,0,1,3,0,0,0,0,0,0,0,1,116,104,105,115,95,99,111,117,
             108,100,95,98,101,95,97,95,109,101,115,115,97,103,101,95,105,100,
             0,0,29,0,31,109,121,95,97,100,100,105,116,105,111,110,97,108,95,
             115,116,97,116,117,115,95,105,110,102,111,95,116,101,120,116,0,4,
             32,0,1,0>>
Got      : <<0,0,0,83,128,0,1,3,0,0,0,0,0,0,0,1,116,104,105,115,95,99,111,117,
             108,100,95,98,101,95,97,95,109,101,115,115,97,103,101,95,105,100,
             0,4,32,0,1,0,0,29,0,31,109,121,95,97,100,100,105,116,105,111,110,
             97,108,95,115,116,97,116,117,115,95,105,110,102,111,95,116,101,
             120,116,0>>

*** CT Error Notification 2018-06-04 04:47:37.401 ***
smpp_test_utils:'-unpack_map_pack/1-fun-1-' failed on line 60
Reason: assertEqual
walter-weinmann commented 6 years ago

Error with unpack_pack

*** User 2018-06-04 04:47:37.839 ***
smpp_test_utils:unpack_pack:71 ===> unbind
#{additional_status_info_text => "my_additional_status_info_text",
  command_id => 2147483907,command_length => 83,command_status => 0,
  dpf_result => 0,message_id => "this_could_be_a_message_id",
  sequence_number => 1}
{
  "additional_status_info_text": "my_additional_status_info_text",
  "command_id": 2147483907,
  "command_length": 83,
  "command_status": 0,
  "dpf_result": 0,
  "message_id": "this_could_be_a_message_id",
  "sequence_number": 1
}

*** User 2018-06-04 04:47:37.839 ***
smpp_test_utils:unpack_pack:74 ===> 
Expected : <<0,0,0,83,128,0,1,3,0,0,0,0,0,0,0,1,116,104,105,115,95,99,111,117,
             108,100,95,98,101,95,97,95,109,101,115,115,97,103,101,95,105,100,
             0,0,29,0,31,109,121,95,97,100,100,105,116,105,111,110,97,108,95,
             115,116,97,116,117,115,95,105,110,102,111,95,116,101,120,116,0,4,
             32,0,1,0>>
Got      : <<0,0,0,83,128,0,1,3,0,0,0,0,0,0,0,1,116,104,105,115,95,99,111,117,
             108,100,95,98,101,95,97,95,109,101,115,115,97,103,101,95,105,100,
             0,4,32,0,1,0,0,29,0,31,109,121,95,97,100,100,105,116,105,111,110,
             97,108,95,115,116,97,116,117,115,95,105,110,102,111,95,116,101,
             120,116,0>>

*** CT Error Notification 2018-06-04 04:47:37.839 ***
smpp_test_utils:'-unpack_pack/1-fun-1-' failed on line 77
Reason: assertEqual
c-bik commented 6 years ago

Please see : https://github.com/K2InformaticsGmbH/smpp_parser/issues/88#issuecomment-394324504

walter-weinmann commented 6 years ago

Fixed with latest version.