Dan Kenigsberg has posted comments on this change.

Change subject: add arguments parser to testrunner
......................................................................


Patch Set 4: I would prefer that you didn't submit this

(8 inline comments)

....................................................
File tests/testrunner.py
Line 43: colorSuitTip = TermColor.magenta
* it is a CONSTATNT,
* there is no need to have it as a 1st class public member of this module, or 
at all.

Line 196:     parser.add_argument('case', nargs='*', help='specify cases to 
run.')
case -> cases (or testCases)

would hint that there's more than one case.

Line 197:     parser.add_argument('--local_modules', action='store_true',
what about the underscore? use dash. that's more standard ans easier to type.

Line 199:     inputArgs = sys.argv[1:]
I personally don't like defining one-use variables whose name does not help 
understand the code better.

Line 201:     testSuitConfig = {"case": None, "local_modules": False}  # 
default values
I love comments, but here it is quite clear that these are default values.

Line 204:     return testSuitConfig
do we really need the dictionary testSuitConfig ? passing "args" as is would do 
fine, I believe.

Line 208:     """Now it only overwrite the vdsm library."""
this function's name is very vague, and its docstring does not help.

Line 211:         colorWrite(stream, "hacking vdsm modules...\n", colorSuitTip)
the user does not need to know that we have a hack in order to use the local 
modules. He asked for local_modules, and he's got it.

--
To view, visit http://gerrit.ovirt.org/4730
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I34cde3b61d394eb651da7c4b544a7c00ab4338f2
Gerrit-PatchSet: 4
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Wenchao Xia <[email protected]>
Gerrit-Reviewer: Adam Litke <[email protected]>
Gerrit-Reviewer: Dan Kenigsberg <[email protected]>
Gerrit-Reviewer: Royce Lv <[email protected]>
Gerrit-Reviewer: Shu Ming <[email protected]>
Gerrit-Reviewer: Wenchao Xia <[email protected]>
_______________________________________________
vdsm-patches mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to