[Asterisk-code-review] pjsip rls large notify test - fails to send notify due (testsuite[master])

Kevin Harwell asteriskteam at digium.com
Fri Sep 25 12:09:37 CDT 2015


Kevin Harwell has uploaded a new change for review.

  https://gerrit.asterisk.org/1314

Change subject: pjsip rls large notify test - fails to send notify due
......................................................................

pjsip rls large notify test - fails to send notify due

This test was not sending the notify because of an unsupported transport error.
What's happening was there was no transport associated with the contact, so it
would default to UDP and since the test was configured for TCP and not UDP it
failed to find a transport. Adding a transport parameter to the contact header
ensures the use of the correct transport.

Also, even though this test failed to send the notify it was still passing
because the test simply timed out with no failure condition. To fix this a
failure condition was also added that checks to make sure a particular event
is received, and if it isn't then it will fail.

ASTERISK-25363

Change-Id: I1a61a7efd72bfe8681b684510433b57df7b9c5a8
---
M tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/sipp/subscribe.xml
M tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/test-config.yaml
2 files changed, 20 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.asterisk.org:29418/testsuite refs/changes/14/1314/1

diff --git a/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/sipp/subscribe.xml b/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/sipp/subscribe.xml
index c713984..af387ee 100644
--- a/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/sipp/subscribe.xml
+++ b/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/sipp/subscribe.xml
@@ -11,7 +11,7 @@
       To: sut <sip:[service]@[remote_ip]:[remote_port]>
       Call-ID: [call_id]
       CSeq: 1 SUBSCRIBE
-      Contact: sip:sipp@[local_ip]:[local_port]
+      Contact: <sip:sipp@[local_ip]:[local_port];transport=tcp>
       Max-Forwards: 70
       Subject: Performance Test
       Event: presence
diff --git a/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/test-config.yaml b/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/test-config.yaml
index e28bae1..d7d6dd8 100644
--- a/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/test-config.yaml
+++ b/tests/channels/pjsip/subscriptions/rls/lists/off_nominal/large_notify/test-config.yaml
@@ -22,9 +22,28 @@
     test-object:
         config-section: 'sipp-config'
         typename: 'sipp.SIPpTestCase'
+    modules:
+        -
+            config-section: 'ami-config'
+            typename: 'ami.AMIEventModule'
 
 sipp-config:
     test-iterations:
         -
             scenarios:
                 - { 'key-args': {'scenario': 'subscribe.xml', '-i': '127.0.0.1', '-p': '5061', '-s': 'pres_list', '-t': 't1'} }
+
+ami-config:
+    -
+        type: 'headermatch'
+        id: '1'
+        conditions:
+            match:
+                Event: 'TestEvent'
+                Type: 'StateChange'
+                State: 'SUBSCRIPTION_STATE_SET'
+                Endpoint: 'sipp'
+        requirements:
+            match:
+                StateText: 'ACTIVE'
+        count: '>0'

-- 
To view, visit https://gerrit.asterisk.org/1314
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1a61a7efd72bfe8681b684510433b57df7b9c5a8
Gerrit-PatchSet: 1
Gerrit-Project: testsuite
Gerrit-Branch: master
Gerrit-Owner: Kevin Harwell <kharwell at digium.com>



More information about the asterisk-code-review mailing list