[Asterisk-code-review] Testsuite: Refactored 'rls validation' Module for Easier Deb... (testsuite[master])
Ashley Sanders
asteriskteam at digium.com
Wed Nov 11 13:49:42 CST 2015
Ashley Sanders has posted comments on this change.
Change subject: Testsuite: Refactored 'rls_validation' Module for Easier Debugging
......................................................................
Patch Set 1:
(2 comments)
https://gerrit.asterisk.org/#/c/1537/1/tests/channels/pjsip/subscriptions/rls/rls_element.py
File tests/channels/pjsip/subscriptions/rls/rls_element.py:
Line 902: LOGGER.debug("Processing RLMI resource -- Inspecting number of " \
: "'name' elements. Expecting: 1.")
> What's the purpose of the backslash line continuation here?
I did not realize until just now that if the string literal is within parenthesis, the continuation character is not necessary. I think that will apply for most of the continuation character usages inside of this module, actually.
http://stackoverflow.com/a/3346295
Line 1007: message = "Processing RLS packet -- Validation check failed. " \
: "Received unexpected number of parts ({0}) in " \
: "multipart body.".format(body_parts - 1)
> Only pointing this out since I got hit on a similar issue with \ continuing
I didn't realize that this wasn't the preferred Pythonic way (and not portable to Python 3) until just now. I will modify to use the parenthesis instead of the continuation character.
For anyone who is interested:
http://stackoverflow.com/a/3346295
http://stackoverflow.com/a/53200
http://stackoverflow.com/a/18160132
--
To view, visit https://gerrit.asterisk.org/1537
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Icb8af439f5c3db3efb0a93d6402ab4dcacdf3731
Gerrit-PatchSet: 1
Gerrit-Project: testsuite
Gerrit-Branch: master
Gerrit-Owner: Ashley Sanders <asanders at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Ashley Sanders <asanders at digium.com>
Gerrit-Reviewer: Jonathan Rose <jrose at digium.com>
Gerrit-HasComments: Yes
More information about the asterisk-code-review
mailing list