2230
flex_compact_otp7431_msg01(suite) ->
2232
flex_compact_otp7431_msg01(Config) when list(Config) ->
2233
%% put(severity,trc),
2235
d("flex_comppact_otp7431_msg01 -> entry", []),
2236
Conf = flex_scanner_conf(Config),
2237
flex_compact_otp7431(ok, flex_compact_otp7431_msg1(), [Conf]).
2239
flex_compact_otp7431_msg02(suite) ->
2241
flex_compact_otp7431_msg02(Config) when list(Config) ->
2242
%% put(severity,trc),
2244
d("flex_comppact_otp7431_msg02 -> entry", []),
2245
Conf = flex_scanner_conf(Config),
2246
flex_compact_otp7431(error, flex_compact_otp7431_msg2(), [Conf]).
2248
flex_compact_otp7431_msg03(suite) ->
2250
flex_compact_otp7431_msg03(Config) when list(Config) ->
2251
%% put(severity,trc),
2253
d("flex_comppact_otp7431_msg03 -> entry", []),
2254
Conf = flex_scanner_conf(Config),
2255
flex_compact_otp7431(error, flex_compact_otp7431_msg3(), [Conf]).
2257
flex_compact_otp7431_msg04(suite) ->
2259
flex_compact_otp7431_msg04(Config) when list(Config) ->
2260
%% put(severity,trc),
2262
d("flex_comppact_otp7431_msg04 -> entry", []),
2263
Conf = flex_scanner_conf(Config),
2264
flex_compact_otp7431(error, flex_compact_otp7431_msg4(), [Conf]).
2266
flex_compact_otp7431_msg05(suite) ->
2268
flex_compact_otp7431_msg05(Config) when list(Config) ->
2269
%% put(severity,trc),
2271
d("flex_comppact_otp7431_msg05 -> entry", []),
2272
Conf = flex_scanner_conf(Config),
2273
flex_compact_otp7431(error, flex_compact_otp7431_msg5(), [Conf]).
2275
flex_compact_otp7431_msg06(suite) ->
2277
flex_compact_otp7431_msg06(Config) when list(Config) ->
2278
%% put(severity,trc),
2280
d("flex_comppact_otp7431_msg06 -> entry", []),
2281
Conf = flex_scanner_conf(Config),
2282
flex_compact_otp7431(error, flex_compact_otp7431_msg6(), [Conf]).
2284
flex_compact_otp7431_msg07(suite) ->
2286
flex_compact_otp7431_msg07(Config) when list(Config) ->
2287
%% put(severity,trc),
2289
d("flex_comppact_otp7431_msg07 -> entry", []),
2290
Conf = flex_scanner_conf(Config),
2291
flex_compact_otp7431(error, flex_compact_otp7431_msg7(), [Conf]).
2294
flex_compact_otp7431(Expected, Msg, Conf) ->
2295
otp7431(Expected, megaco_compact_text_encoder, Msg, Conf).
2297
flex_compact_otp7431_msg1() ->
2298
"!/1 [124.124.124.222]:55555
2299
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2301
o=- 2890844526 2890842807 IN IP4 124.124.124.222
2304
c=IN IP4 124.124.124.222
2305
m=audio 2222 RTP/AVP 4
2310
flex_compact_otp7431_msg2() ->
2311
"!/1 [124.124.124.222]:55555
2312
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2314
o=- 2890844526 2890842807 IN IP4 124.124.124.222
2317
c=IN IP4 124.124.124.222
2318
m=audio 2222 RTP/AVP 4
2324
flex_compact_otp7431_msg3() ->
2325
"!/1 [124.124.124.222]:55555
2326
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2328
o=- 2890844526 2890842807 IN IP4 124.124.124.222
2331
c=IN IP4 124.124.124.222
2332
m=audio 2222 RTP/AVP 4
2338
flex_compact_otp7431_msg4() ->
2339
"!/1 [124.124.124.222]:55555
2340
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2342
o=- 2890844526 2890842807 IN IP4 124.124.124.222
2345
c=IN IP4 124.124.124.222
2346
m=audio 2222 RTP/AVP 4
2352
flex_compact_otp7431_msg5() ->
2353
"!/1 [124.124.124.222]:55555
2354
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2359
flex_compact_otp7431_msg6() ->
2360
"!/1 [124.124.124.222]:55555
2361
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2365
flex_compact_otp7431_msg7() ->
2366
"!/1 [124.124.124.222]:55555
2367
P=10003{C=2000{A=a4444,A=a4445{M{ST=1{L{
2201
2372
%% ==============================================================
2203
2374
%% P r e t t y T e s t c a s e s
4065
flex_pretty_otp7431_msg01(suite) ->
4067
flex_pretty_otp7431_msg01(Config) when list(Config) ->
4068
d("flex_pretty_otp7431_msg01 -> entry", []),
4069
?ACQUIRE_NODES(1, Config),
4070
Conf = flex_scanner_conf(Config),
4071
flex_pretty_otp7431(ok, flex_pretty_otp7431_msg1(), [Conf]).
4073
flex_pretty_otp7431_msg02(suite) ->
4075
flex_pretty_otp7431_msg02(Config) when list(Config) ->
4076
%% put(severity,trc),
4078
d("flex_pretty_otp7431_msg02 -> entry", []),
4079
?ACQUIRE_NODES(1, Config),
4080
Conf = flex_scanner_conf(Config),
4081
flex_pretty_otp7431(error, flex_pretty_otp7431_msg2(), [Conf]).
4083
flex_pretty_otp7431_msg03(suite) ->
4085
flex_pretty_otp7431_msg03(Config) when list(Config) ->
4086
%% put(severity,trc),
4088
d("flex_pretty_otp7431_msg03 -> entry", []),
4089
?ACQUIRE_NODES(1, Config),
4090
Conf = flex_scanner_conf(Config),
4091
flex_pretty_otp7431(error, flex_pretty_otp7431_msg3(), [Conf]).
4093
flex_pretty_otp7431_msg04(suite) ->
4095
flex_pretty_otp7431_msg04(Config) when list(Config) ->
4096
d("flex_pretty_otp7431_msg04 -> entry", []),
4097
?ACQUIRE_NODES(1, Config),
4098
Conf = flex_scanner_conf(Config),
4099
flex_pretty_otp7431(error, flex_pretty_otp7431_msg4(), [Conf]).
4101
flex_pretty_otp7431_msg05(suite) ->
4103
flex_pretty_otp7431_msg05(Config) when list(Config) ->
4104
d("flex_pretty_otp7431_msg05 -> entry", []),
4105
?ACQUIRE_NODES(1, Config),
4106
Conf = flex_scanner_conf(Config),
4107
flex_pretty_otp7431(error, flex_pretty_otp7431_msg5(), [Conf]).
4109
flex_pretty_otp7431_msg06(suite) ->
4111
flex_pretty_otp7431_msg06(Config) when list(Config) ->
4112
d("flex_pretty_otp7431_msg06 -> entry", []),
4113
?ACQUIRE_NODES(1, Config),
4114
Conf = flex_scanner_conf(Config),
4115
flex_pretty_otp7431(error, flex_pretty_otp7431_msg6(), [Conf]).
4117
flex_pretty_otp7431_msg07(suite) ->
4119
flex_pretty_otp7431_msg07(Config) when list(Config) ->
4120
d("flex_pretty_otp7431_msg07 -> entry", []),
4121
?ACQUIRE_NODES(1, Config),
4122
Conf = flex_scanner_conf(Config),
4123
flex_pretty_otp7431(error, flex_pretty_otp7431_msg7(), [Conf]).
4125
flex_pretty_otp7431(Expected, Msg, Conf) ->
4126
otp7431(Expected, megaco_pretty_text_encoder, Msg, Conf).
4128
otp7431(Expected, Codec, Msg0, Conf0) ->
4129
Bin0 = list_to_binary(Msg0),
4130
Conf = [?EC_V3|Conf0],
4131
case decode_message(Codec, false, Conf, Bin0) of
4132
{ok, _Msg1} when Expected =:= ok ->
4133
io:format(" decoded", []);
4134
{error, {bad_property_parm, Reason}} when (Expected =:= error) andalso
4136
io:format("expected result: ~s", [Reason]),
4139
io:format("unexpected result", []),
4140
exit({unexpected_decode_result, Else})
4144
flex_pretty_otp7431_msg1() ->
4145
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
4153
o=- 2890844526 2890842807 IN IP4 124.124.124.222
4156
c=IN IP4 124.124.124.222
4157
m=audio 2222 RTP/AVP 4
4160
} ; RTP profile for G.723.1 is 4
4167
flex_pretty_otp7431_msg2() ->
4168
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
4176
o=- 2890844526 2890842807 IN IP4 124.124.124.222
4179
c=IN IP4 124.124.124.222
4180
m=audio 2222 RTP/AVP 4
4189
flex_pretty_otp7431_msg3() ->
4190
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
4198
o=- 2890844526 2890842807 IN IP4 124.124.124.222
4201
c=IN IP4 124.124.124.222
4202
m=audio 2222 RTP/AVP 4
4211
flex_pretty_otp7431_msg4() ->
4212
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
4220
o=- 2890844526 2890842807 IN IP4 124.124.124.222
4223
c=IN IP4 124.124.124.222
4224
m=audio 2222 RTP/AVP 4
4233
flex_pretty_otp7431_msg5() ->
4234
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
4248
flex_pretty_otp7431_msg6() ->
4249
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
4263
flex_pretty_otp7431_msg7() ->
4264
"MEGACO/" ?VERSION_STR " [124.124.124.222]:55555 Reply = 10003 {
3894
4279
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%