[asterisk-commits] 'escape-pattern' should default to 'False' if not specified (testsuite[master])

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Jun 8 17:34:43 CDT 2015


Joshua Colp has submitted this change and it was merged.

Change subject: 'escape-pattern' should default to 'False' if not specified
......................................................................


'escape-pattern' should default to 'False' if not specified

If not specified in the yaml config the 'escape-pattern' option was defaulting
to 'True'. This caused some tests to fail due to the pattern being escaped
before being matched. This patch defaults the option to 'False'.

Reported by: jbigelow

Change-Id: I836b30c867f5a36580e5dc525121a58aba4c87db
---
M lib/python/asterisk/ami.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  John Bigelow: Looks good to me, but someone else must approve
  Joshua Colp: Looks good to me, approved; Verified



diff --git a/lib/python/asterisk/ami.py b/lib/python/asterisk/ami.py
index f3a8e00..8958c8b 100644
--- a/lib/python/asterisk/ami.py
+++ b/lib/python/asterisk/ami.py
@@ -46,7 +46,7 @@
         self._event_observers = []
         self.count = {}
 
-        if instance_config.get('escape-pattern', True):
+        if instance_config.get('escape-pattern', False):
             self.match = (lambda pattern, s, flags=0:
                           re.match(re.escape(pattern), s, flags))
         else:

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I836b30c867f5a36580e5dc525121a58aba4c87db
Gerrit-PatchSet: 1
Gerrit-Project: testsuite
Gerrit-Branch: master
Gerrit-Owner: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: John Bigelow <jbigelow at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>



More information about the asterisk-commits mailing list