aboutsummaryrefslogtreecommitdiffstats
path: root/test/framework.py
diff options
context:
space:
mode:
authorKlement Sekera <ksekera@cisco.com>2017-01-04 12:58:53 +0100
committerDamjan Marion <dmarion.lists@gmail.com>2017-01-11 23:26:16 +0000
commitda505f608e0919c45089dc80f9e3e16330a6551a (patch)
tree9ed1acf859ac883ba96e64b6f791047d1d6691b1 /test/framework.py
parenta48ad28256d0bc0de8a64f4b04f86fde39248d67 (diff)
make test: improve documentation and PEP8 compliance
Change-Id: Ib4f0353aab6112fcc3c3d8f0bcbed5bc4b567b9b Signed-off-by: Klement Sekera <ksekera@cisco.com>
Diffstat (limited to 'test/framework.py')
-rw-r--r--test/framework.py23
1 files changed, 12 insertions, 11 deletions
diff --git a/test/framework.py b/test/framework.py
index 896a1e0d538..b2c6b9e4555 100644
--- a/test/framework.py
+++ b/test/framework.py
@@ -117,7 +117,8 @@ class VppTestCase(unittest.TestCase):
debug_cli = ""
if cls.step or cls.debug_gdb or cls.debug_gdbserver:
debug_cli = "cli-listen localhost:5002"
- cls.vpp_cmdline = [cls.vpp_bin, "unix", "{", "nodaemon", debug_cli, "}",
+ cls.vpp_cmdline = [cls.vpp_bin,
+ "unix", "{", "nodaemon", debug_cli, "}",
"api-segment", "{", "prefix", cls.shm_prefix, "}"]
if cls.plugin_path is not None:
cls.vpp_cmdline.extend(["plugin_path", cls.plugin_path])
@@ -246,8 +247,8 @@ class VppTestCase(unittest.TestCase):
print(double_line_delim)
print("VPP or GDB server is still running")
print(single_line_delim)
- raw_input("When done debugging, press ENTER to kill the process"
- " and finish running the testcase...")
+ raw_input("When done debugging, press ENTER to kill the "
+ "process and finish running the testcase...")
if hasattr(cls, 'vpp'):
if hasattr(cls, 'vapi'):
@@ -563,10 +564,10 @@ class VppTestResult(unittest.TestResult):
def __init__(self, stream, descriptions, verbosity):
"""
- :param stream File descriptor to store where to report test results. Set
- to the standard error stream by default.
- :param descriptions Boolean variable to store information if to use test
- case descriptions.
+ :param stream File descriptor to store where to report test results.
+ Set to the standard error stream by default.
+ :param descriptions Boolean variable to store information if to use
+ test case descriptions.
:param verbosity Integer variable to store required verbosity level.
"""
unittest.TestResult.__init__(self, stream, descriptions, verbosity)
@@ -664,12 +665,12 @@ class VppTestResult(unittest.TestResult):
unittest.TestResult.stopTest(self, test)
if self.verbosity > 0:
self.stream.writeln(single_line_delim)
- self.stream.writeln("%-60s%s" %
- (self.getDescription(test), self.result_string))
+ self.stream.writeln("%-60s%s" % (self.getDescription(test),
+ self.result_string))
self.stream.writeln(single_line_delim)
else:
- self.stream.writeln("%-60s%s" %
- (self.getDescription(test), self.result_string))
+ self.stream.writeln("%-60s%s" % (self.getDescription(test),
+ self.result_string))
def printErrors(self):
"""