[Asterisk-code-review] StatsD: Create a mock StatsD server in the Testsuite (testsuite[master])

Matt Jordan asteriskteam at digium.com
Mon Oct 5 14:32:13 CDT 2015


Matt Jordan has posted comments on this change.

Change subject: StatsD: Create a mock StatsD server in the Testsuite
......................................................................


Patch Set 4: Code-Review-1

(4 comments)

https://gerrit.asterisk.org/#/c/1313/4/tests/apps/statsd/nominal/mockd.py
File tests/apps/statsd/nominal/mockd.py:

Line 84:             return
For readability, add some vertical whitespace between each conditional block:

if (check something):
    do some stuff
    return

if (check something else):
    do some other stuff
    return

okay, everything is good
set test to passed
return


Line 85:         failed_matches = [[actual, expected] for actual, expected in
This should be a tuple here, not a list:

[(actual, expected) for ...


Line 92:         else:
No need for the else, since you return if the length of the failed matches is 0.


Line 96:         LOGGER.debug('Test is stopping')
This will never execute, as both code paths above it return.


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I4eaf92465b79569fff4db6ada16e8d215f7d214b
Gerrit-PatchSet: 4
Gerrit-Project: testsuite
Gerrit-Branch: master
Gerrit-Owner: Tyler Cambron <tcambron at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Ashley Sanders <asanders at digium.com>
Gerrit-Reviewer: Matt Jordan <mjordan at digium.com>
Gerrit-HasComments: Yes



More information about the asterisk-code-review mailing list