[asterisk-commits] pjsip/configuration/duplicate sections: Remove type=contact ... (testsuite[master])

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sat Nov 21 17:59:08 CST 2015


Anonymous Coward #1000019 has submitted this change and it was merged.

Change subject: pjsip/configuration/duplicate_sections: Remove type=contact duplication check.
......................................................................


pjsip/configuration/duplicate_sections: Remove type=contact duplication check.

Contacts are not specified in configuration files. They are
created as a result of a static specified or a dynamically
added contact.

Change-Id: I459841c21387a74524f7c0b5ab1349216bb2ff53
---
M tests/channels/pjsip/configuration/duplicate_sections/configs/ast3/pjsip.conf
M tests/channels/pjsip/configuration/duplicate_sections/configs/ast4/pjsip.conf
M tests/channels/pjsip/configuration/duplicate_sections/configs/ast5/pjsip.conf
M tests/channels/pjsip/configuration/duplicate_sections/configs/ast6/pjsip.conf
D tests/channels/pjsip/configuration/duplicate_sections/configs/ast7/pjsip.conf
M tests/channels/pjsip/configuration/duplicate_sections/test-config.yaml
6 files changed, 42 insertions(+), 165 deletions(-)

Approvals:
  Anonymous Coward #1000019: Verified
  Matt Jordan: Looks good to me, approved



diff --git a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast3/pjsip.conf b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast3/pjsip.conf
index 98ab555..f8f726d 100644
--- a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast3/pjsip.conf
+++ b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast3/pjsip.conf
@@ -74,7 +74,7 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 [siptrunk](acl-template)
-contactpermit=127.0.0.3
+contactpermit=127.0.0.4
 
 [siptrunk](aor-template)
 contact=siptrunk
@@ -85,7 +85,7 @@
 password=bar
 
 [siptrunk](contact-template)
-contact=sip:siptrunk at 127.0.0.3:5062
+contact=sip:siptrunk at 127.0.0.4:5062
 
 [siptrunk](domain-alias-template)
 domain=foo.com
@@ -98,22 +98,24 @@
 
 [siptrunk](identify-template)
 endpoint=siptrunk
-match=127.0.0.3
+match=127.0.0.4
 
 [siptrunk](registration-template)
-client_uri=sip:siptrunk at 127.0.0.3:5061
+client_uri=sip:siptrunk at 127.0.0.4:5061
 server_uri=siptrunk
 contact_user=siptrunk
 outbound_auth=siptrunk
 transport=siptrunk
 
 [siptrunk](transport-template)
-bind=127.0.0.3:5061
+bind=127.0.0.4:5061
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; duplicate entry
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
-[siptrunk](contact-template)
-contact=sip:siptrunk at 127.0.0.3:5062
-
+[siptrunk](endpoint-template)
+aors=siptrunk
+auth=siptrunk
+from_user=siptrunk
+outbound_auth=siptrunk
diff --git a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast4/pjsip.conf b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast4/pjsip.conf
index f8f726d..4e465e1 100644
--- a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast4/pjsip.conf
+++ b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast4/pjsip.conf
@@ -74,7 +74,7 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 [siptrunk](acl-template)
-contactpermit=127.0.0.4
+contactpermit=127.0.0.5
 
 [siptrunk](aor-template)
 contact=siptrunk
@@ -85,7 +85,7 @@
 password=bar
 
 [siptrunk](contact-template)
-contact=sip:siptrunk at 127.0.0.4:5062
+contact=sip:siptrunk at 127.0.0.5:5062
 
 [siptrunk](domain-alias-template)
 domain=foo.com
@@ -98,24 +98,22 @@
 
 [siptrunk](identify-template)
 endpoint=siptrunk
-match=127.0.0.4
+match=127.0.0.5
 
 [siptrunk](registration-template)
-client_uri=sip:siptrunk at 127.0.0.4:5061
+client_uri=sip:siptrunk at 127.0.0.5:5061
 server_uri=siptrunk
 contact_user=siptrunk
 outbound_auth=siptrunk
 transport=siptrunk
 
 [siptrunk](transport-template)
-bind=127.0.0.4:5061
+bind=127.0.0.5:5061
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; duplicate entry
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
-[siptrunk](endpoint-template)
-aors=siptrunk
-auth=siptrunk
-from_user=siptrunk
-outbound_auth=siptrunk
+[siptrunk](identify-template)
+endpoint=siptrunk
+match=127.0.0.5
\ No newline at end of file
diff --git a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast5/pjsip.conf b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast5/pjsip.conf
index 4e465e1..e24d736 100644
--- a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast5/pjsip.conf
+++ b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast5/pjsip.conf
@@ -74,7 +74,7 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 [siptrunk](acl-template)
-contactpermit=127.0.0.5
+contactpermit=127.0.0.6
 
 [siptrunk](aor-template)
 contact=siptrunk
@@ -85,7 +85,7 @@
 password=bar
 
 [siptrunk](contact-template)
-contact=sip:siptrunk at 127.0.0.5:5062
+contact=sip:siptrunk at 127.0.0.6:5062
 
 [siptrunk](domain-alias-template)
 domain=foo.com
@@ -98,22 +98,25 @@
 
 [siptrunk](identify-template)
 endpoint=siptrunk
-match=127.0.0.5
+match=127.0.0.6
 
 [siptrunk](registration-template)
-client_uri=sip:siptrunk at 127.0.0.5:5061
+client_uri=sip:siptrunk at 127.0.0.6:5061
 server_uri=siptrunk
 contact_user=siptrunk
 outbound_auth=siptrunk
 transport=siptrunk
 
 [siptrunk](transport-template)
-bind=127.0.0.5:5061
+bind=127.0.0.6:5061
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; duplicate entry
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
-[siptrunk](identify-template)
-endpoint=siptrunk
-match=127.0.0.5
\ No newline at end of file
+[siptrunk](registration-template)
+client_uri=sip:siptrunk at 127.0.0.6:5061
+server_uri=siptrunk
+contact_user=siptrunk
+outbound_auth=siptrunk
+transport=siptrunk
\ No newline at end of file
diff --git a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast6/pjsip.conf b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast6/pjsip.conf
index e24d736..6429711 100644
--- a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast6/pjsip.conf
+++ b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast6/pjsip.conf
@@ -74,7 +74,7 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 [siptrunk](acl-template)
-contactpermit=127.0.0.6
+contactpermit=127.0.0.7
 
 [siptrunk](aor-template)
 contact=siptrunk
@@ -85,7 +85,7 @@
 password=bar
 
 [siptrunk](contact-template)
-contact=sip:siptrunk at 127.0.0.6:5062
+contact=sip:siptrunk at 127.0.0.7:5062
 
 [siptrunk](domain-alias-template)
 domain=foo.com
@@ -98,25 +98,21 @@
 
 [siptrunk](identify-template)
 endpoint=siptrunk
-match=127.0.0.6
+match=127.0.0.7
 
 [siptrunk](registration-template)
-client_uri=sip:siptrunk at 127.0.0.6:5061
+client_uri=sip:siptrunk at 127.0.0.7:5061
 server_uri=siptrunk
 contact_user=siptrunk
 outbound_auth=siptrunk
 transport=siptrunk
 
 [siptrunk](transport-template)
-bind=127.0.0.6:5061
+bind=127.0.0.7:5061
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ; duplicate entry
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
-[siptrunk](registration-template)
-client_uri=sip:siptrunk at 127.0.0.6:5061
-server_uri=siptrunk
-contact_user=siptrunk
-outbound_auth=siptrunk
-transport=siptrunk
\ No newline at end of file
+[siptrunk](transport-template)
+bind=127.0.0.7:5061
\ No newline at end of file
diff --git a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast7/pjsip.conf b/tests/channels/pjsip/configuration/duplicate_sections/configs/ast7/pjsip.conf
deleted file mode 100644
index 6429711..0000000
--- a/tests/channels/pjsip/configuration/duplicate_sections/configs/ast7/pjsip.conf
+++ /dev/null
@@ -1,118 +0,0 @@
-[global]
-type=global
-debug=yes
-
-[acl-template](!)
-type=acl
-contactdeny=0.0.0.0/0.0.0.0
-
-[aor-template](!)
-type=aor
-default_expiration=240
-max_contacts=5
-minimum_expiration=240
-maximum_expiration=3600
-qualify_frequency=900
-
-[auth-template](!)
-type=auth
-auth_type=userpass
-realm=asterisk
-
-[contact-template](!)
-type=contact
-qualify_frequency=0
-
-[domain-alias-template](!)
-type=domain_alias
-
-[endpoint-template](!)
-type=endpoint
-transport=trans
-disallow=all
-allow=ulaw
-allow_subscribe=yes
-allow_transfer=yes
-callerid=uut_callerid_name <uut_callerid_num>
-callerid_privacy=allowed
-connected_line_method=invite
-context=local
-device_state_busy_at=0
-direct_media=no
-fax_detect=no
-force_rport=yes
-from_domain=
-from_user=
-rewrite_contact=no
-t38_udptl=no
-t38_udptl_ec=none
-t38_udptl_ipv6=no
-t38_udptl_maxdatagram=0
-t38_udptl_nat=no
-trust_id_inbound=no
-trust_id_outbound=no
-
-[identify-template](!)
-type=identify
-
-[registration-template](!)
-type=registration
-auth_rejection_permanent=no
-expiration=3600
-forbidden_retry_interval=0
-max_retries=10
-outbound_proxy=
-retry_interval=60
-
-[system-template](!)
-type=system
-
-[transport-template](!)
-type=transport
-protocol=udp
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-[siptrunk](acl-template)
-contactpermit=127.0.0.7
-
-[siptrunk](aor-template)
-contact=siptrunk
-mailboxes=4000 at default
-
-[siptrunk](auth-template)
-username=foo
-password=bar
-
-[siptrunk](contact-template)
-contact=sip:siptrunk at 127.0.0.7:5062
-
-[siptrunk](domain-alias-template)
-domain=foo.com
-
-[siptrunk](endpoint-template)
-aors=siptrunk
-auth=siptrunk
-from_user=siptrunk
-outbound_auth=siptrunk
-
-[siptrunk](identify-template)
-endpoint=siptrunk
-match=127.0.0.7
-
-[siptrunk](registration-template)
-client_uri=sip:siptrunk at 127.0.0.7:5061
-server_uri=siptrunk
-contact_user=siptrunk
-outbound_auth=siptrunk
-transport=siptrunk
-
-[siptrunk](transport-template)
-bind=127.0.0.7:5061
-
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-; duplicate entry
-;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
-[siptrunk](transport-template)
-bind=127.0.0.7:5061
\ No newline at end of file
diff --git a/tests/channels/pjsip/configuration/duplicate_sections/test-config.yaml b/tests/channels/pjsip/configuration/duplicate_sections/test-config.yaml
index 856c4b2..87dd9ae 100644
--- a/tests/channels/pjsip/configuration/duplicate_sections/test-config.yaml
+++ b/tests/channels/pjsip/configuration/duplicate_sections/test-config.yaml
@@ -4,7 +4,7 @@
         entries are defined in pjsip.conf.
     description: |
         This test ensures Asterisk gracefully handles the situation where
-        duplicate sections are defined in pjsip.conf. Seven (7) test
+        duplicate sections are defined in pjsip.conf. Six (6) test
         scenarios are utilized to confirm configuring pjsip.conf with sections
         containing an identical id/type combination as another section in the
         file, results in Asterisk rejecting the configuration. Each test
@@ -12,11 +12,10 @@
         combination. The test scenarios:
         Scenario [1] -> ast1: Tests duplicate [id=siptrunk, type=aor] sections
         Scenario [2] -> ast2: Tests duplicate [id=siptrunk, type=auth] sections
-        Scenario [3] -> ast3: Tests duplicate [id=siptrunk, type=contact] sections
-        Scenario [4] -> ast4: Tests duplicate [id=siptrunk, type=endpoint] sections
-        Scenario [5] -> ast5: Tests duplicate [id=siptrunk, type=identify] sections
-        Scenario [6] -> ast6: Tests duplicate [id=siptrunk, type=registration] sections
-        Scenario [7] -> ast7: Tests duplicate [id=siptrunk, type=transport] sections
+        Scenario [3] -> ast3: Tests duplicate [id=siptrunk, type=endpoint] sections
+        Scenario [4] -> ast4: Tests duplicate [id=siptrunk, type=identify] sections
+        Scenario [5] -> ast5: Tests duplicate [id=siptrunk, type=registration] sections
+        Scenario [6] -> ast6: Tests duplicate [id=siptrunk, type=transport] sections
 
 properties:
     minversion: '13.4.0'
@@ -44,7 +43,7 @@
             typename: 'test_harness.TestHarness'
 
 test-object-config:
-    asterisk-instances: 7
+    asterisk-instances: 6
     connect-ami: 'True'
 
 duplicate-sections:
@@ -54,9 +53,6 @@
             output_query: 'No\sobjects\sfound\.'
         -
             cli_command: 'pjsip show auths'
-            output_query: 'No\sobjects\sfound\.'
-        -
-            cli_command: 'pjsip show contacts'
             output_query: 'No\sobjects\sfound\.'
         -
             cli_command: 'pjsip show endpoints'

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I459841c21387a74524f7c0b5ab1349216bb2ff53
Gerrit-PatchSet: 1
Gerrit-Project: testsuite
Gerrit-Branch: master
Gerrit-Owner: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Matt Jordan <mjordan at digium.com>



More information about the asterisk-commits mailing list