[Asterisk-code-review] channels/pjsip/identify/header: Add regex test cases (testsuite[13])

Jenkins2 asteriskteam at digium.com
Fri Aug 3 13:32:42 CDT 2018


Jenkins2 has submitted this change and it was merged. ( https://gerrit.asterisk.org/9722 )

Change subject: channels/pjsip/identify/header: Add regex test cases
......................................................................

channels/pjsip/identify/header: Add regex test cases

ASTERISK-27548

Change-Id: I5d1e132b668bd02f5a88ef1d1ef066a919564da8
---
M tests/channels/pjsip/identify/header/configs/ast1/pjsip.conf
M tests/channels/pjsip/identify/header/test-config.yaml
2 files changed, 14 insertions(+), 3 deletions(-)

Approvals:
  Joshua Colp: Looks good to me, but someone else must approve
  Kevin Harwell: Looks good to me, approved
  Jenkins2: Approved for Submit



diff --git a/tests/channels/pjsip/identify/header/configs/ast1/pjsip.conf b/tests/channels/pjsip/identify/header/configs/ast1/pjsip.conf
index 13226b7..035dc94 100644
--- a/tests/channels/pjsip/identify/header/configs/ast1/pjsip.conf
+++ b/tests/channels/pjsip/identify/header/configs/ast1/pjsip.conf
@@ -1,3 +1,7 @@
+[global]
+type=global
+debug=yes
+
 [system]
 type=system
 timer_t1=100
@@ -21,6 +25,10 @@
 [identify-template](!)
 type=identify
 
-[alice-identify](identify-template)
+[alice-identify-literal](identify-template)
 endpoint=alice
 match_header=X-ASTERISK-TOKEN: e7657250-07fa-11e7-92f8-1b946c0c7e84
+
+[alice-identify-regex](identify-template)
+endpoint=alice
+match_header=X-ASTERISK-TOKEN: /Win.*caca/
diff --git a/tests/channels/pjsip/identify/header/test-config.yaml b/tests/channels/pjsip/identify/header/test-config.yaml
index bc6971d..b4ca25c 100644
--- a/tests/channels/pjsip/identify/header/test-config.yaml
+++ b/tests/channels/pjsip/identify/header/test-config.yaml
@@ -21,9 +21,11 @@
             scenarios:
                 - { 'key-args': {'scenario': 'nominal.xml', '-i': '127.0.0.1', '-p': '5061', '-s': 's'},
                     'ordered-args': ['-key', 'ident_key', 'e7657250-07fa-11e7-92f8-1b946c0c7e84'] }
-                - { 'key-args': {'scenario': 'off-nominal.xml', '-i': '127.0.0.1', '-p': '5062', '-s': 's'},
-                    'ordered-args': ['-key', 'ident_key', 'derp'] }
+                - { 'key-args': {'scenario': 'nominal.xml', '-i': '127.0.0.1', '-p': '5062', '-s': 's'},
+                    'ordered-args': ['-key', 'ident_key', 'Camp Winipcaca summer vacation'] }
                 - { 'key-args': {'scenario': 'off-nominal.xml', '-i': '127.0.0.1', '-p': '5063', '-s': 's'},
+                    'ordered-args': ['-key', 'ident_key', 'derp'] }
+                - { 'key-args': {'scenario': 'off-nominal.xml', '-i': '127.0.0.1', '-p': '5064', '-s': 's'},
                     'ordered-args': ['-key', 'ident_key', ''] }
 
 
@@ -33,5 +35,6 @@
             version : 'v3.0'
         - asterisk : 'app_echo'
         - asterisk : 'res_pjsip'
+        - asterisk : 'res_pjsip_endpoint_identifier_ip'
     tags:
         - pjsip

-- 
To view, visit https://gerrit.asterisk.org/9722
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: testsuite
Gerrit-Branch: 13
Gerrit-MessageType: merged
Gerrit-Change-Id: I5d1e132b668bd02f5a88ef1d1ef066a919564da8
Gerrit-Change-Number: 9722
Gerrit-PatchSet: 1
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180803/414c1950/attachment.html>


More information about the asterisk-code-review mailing list