From c483616a956feee9e1dcbc78d43142982e677afc Mon Sep 17 00:00:00 2001 From: Victor Seva Date: Tue, 22 Jun 2021 11:35:46 +0200 Subject: [PATCH] TT#116103 scenarios/invite: changes to support external SERVER_IP * use server_ip from scenario_ids.yml * Contact with <> format * tests: - add received Contact parameter as optional Change-Id: Ida9b2e06e8de5e042967f08c39ec6f82a7865f60 --- scenarios/invite/0003_test.yml.tt2 | 2 +- scenarios/invite/0005_test.yml.tt2 | 2 +- scenarios/invite/0006_test.yml.tt2 | 8 ++++---- scenarios/invite/0015_test.yml.tt2 | 4 ++-- scenarios/invite/sipp_scenario00.xml | 10 +++++----- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/scenarios/invite/0003_test.yml.tt2 b/scenarios/invite/0003_test.yml.tt2 index 2ed92a4e..ae9292f5 100644 --- a/scenarios/invite/0003_test.yml.tt2 +++ b/scenarios/invite/0003_test.yml.tt2 @@ -22,7 +22,7 @@ flow: - exit|ROUTE_EXIT: sip_in: - '^INVITE' - - 'Contact: sip:testuser1002@' + - 'Contact: ]+)?>' - 'To: ]+)?>' - 'CSeq: 2 INVITE' - 'Max-Forwards: 69' - 'Content-Type: application/sdp' diff --git a/scenarios/invite/0006_test.yml.tt2 b/scenarios/invite/0006_test.yml.tt2 index c34308f6..5ac4909b 100644 --- a/scenarios/invite/0006_test.yml.tt2 +++ b/scenarios/invite/0006_test.yml.tt2 @@ -21,8 +21,8 @@ sip_in: - 'P-Asserted-Identity: ' - 'P-Caller-UUID: [% invite.scenarios.test.testuser1002.uuid %]' - 'P-NGCP-Caller-Info: ;ip=[% scenarios.0.ip %];port=[% scenarios.0.port %];primary=[% invite_scenarios_test.testuser1002.phone_number %]' - - 'P-NGCP-Callee-Info: ;ip=127.0.0.1;port=5060;primary=[% invite_scenarios_test.testuser1003.phone_number %]' - - 'P-D-Uri: sip:lb@127.0.0.1;lr;socket=sip:127.0.0.1:5060' + - 'P-NGCP-Callee-Info: ;ip=[% scenarios.0.responders.0.ip %];port=[% scenarios.0.responders.0.port %];primary=[% invite_scenarios_test.testuser1003.phone_number %]' + - 'P-D-Uri: sip:lb@127.0.0.1;lr;(received=sip:[% scenarios.0.responders.0.ip %]:[% scenarios.0.responders.0.port %];)?socket=sip:[% server_ip %]:5060' - 'Content-Type: application/sdp' - 'Contact: ' - 'Content-Length:\s+\d+' @@ -44,8 +44,8 @@ sip_out: 'P-Asserted-Identity: ', 'P-Caller-UUID: [% invite.scenarios.test.testuser1002.uuid %]', 'P-NGCP-Caller-Info: ;ip=[% scenarios.0.ip %];port=[% scenarios.0.port %];primary=[% invite_scenarios_test.testuser1002.phone_number %]', - 'P-NGCP-Callee-Info: ;ip=127.0.0.1;port=5060;primary=[% invite_scenarios_test.testuser1003.phone_number %]', - 'P-D-Uri: sip:lb@127.0.0.1;lr;socket=sip:127.0.0.1:5060', + 'P-NGCP-Callee-Info: ;ip=[% scenarios.0.responders.0.ip %];port=[% scenarios.0.responders.0.port %];primary=[% invite_scenarios_test.testuser1003.phone_number %]', + 'P-D-Uri: sip:lb@127.0.0.1;lr;(received=sip:[% scenarios.0.responders.0.ip %]:[% scenarios.0.responders.0.port %];)?socket=sip:[% server_ip %]:5060', 'Content-Type: application/sdp', 'Contact: ', 'Content-Length:\s+\d+', diff --git a/scenarios/invite/0015_test.yml.tt2 b/scenarios/invite/0015_test.yml.tt2 index d30768c3..71c2da78 100644 --- a/scenarios/invite/0015_test.yml.tt2 +++ b/scenarios/invite/0015_test.yml.tt2 @@ -29,7 +29,7 @@ flow: - exit|ROUTE_EXIT: sip_in: - '^BYE sip:127.0.0.1:5080(;prxroute=1)? SIP/2.0' - - 'Contact: sip:testuser1002@' + - 'Contact: ]+)?>' - 'CSeq: 3 BYE' - 'Max-Forwards: 69' - 'Content-Length: 0' @@ -46,7 +46,7 @@ sip_out: ] - [ '^BYE sip:127.0.0.1:5080(;prxroute=1)? SIP/2.0', - 'Contact: sip:testuser1002@', + 'Contact: ]+)?>', 'CSeq: 3 BYE', 'Max-Forwards: 68', 'Content-Length: 0', diff --git a/scenarios/invite/sipp_scenario00.xml b/scenarios/invite/sipp_scenario00.xml index 13b3c912..571234b0 100644 --- a/scenarios/invite/sipp_scenario00.xml +++ b/scenarios/invite/sipp_scenario00.xml @@ -10,7 +10,7 @@ To: Call-ID: NGCP%[field4 file="callee.csv" line=0]%///[call_id] CSeq: 1 INVITE - Contact: sip:[field0 file="caller.csv"]@[local_ip]:[local_port] + Contact: Max-Forwards: 70 Content-Type: application/sdp Content-Length: [len] @@ -41,7 +41,7 @@ To: [peer_tag_param] Call-ID: NGCP%[field4 file="callee.csv" line=0]%///[call_id] CSeq: 1 ACK - Contact: sip:[field0 file="caller.csv"]@[local_ip]:[local_port] + Contact: Max-Forwards: 70 Content-Length: 0 @@ -59,7 +59,7 @@ To: Call-ID: NGCP%[field4 file="callee.csv" line=0]%///[call_id] CSeq: 2 INVITE - Contact: sip:[field0 file="caller.csv"]@[local_ip]:[local_port] + Contact: Max-Forwards: 70 [field1 file="caller.csv"] Content-Type: application/sdp @@ -99,7 +99,7 @@ Call-ID: NGCP%[field4 file="callee.csv" line=0]%///[call_id] [routes] CSeq: 2 ACK - Contact: sip:[field0 file="caller.csv"]@[local_ip]:[local_port] + Contact: Max-Forwards: 70 Content-Length: 0 @@ -124,7 +124,7 @@ To: [peer_tag_param] Call-ID: NGCP%[field4 file="callee.csv" line=0]%///[call_id] CSeq: 3 BYE - Contact: sip:[field0 file="caller.csv"]@[local_ip]:[local_port] + Contact: [routes] Max-Forwards: 70 Content-Length: 0