Add an initial stab at docstrings - enable docstring pylinter
This commit is contained in:
5
tests.py
5
tests.py
@ -13,6 +13,7 @@
|
||||
# limitations under the License.
|
||||
#
|
||||
# -*- coding: utf-8 -*-
|
||||
""" This is a unit test suite for vppcfg """
|
||||
|
||||
import sys
|
||||
import glob
|
||||
@ -36,6 +37,8 @@ def example_validator(_yaml):
|
||||
|
||||
|
||||
class YAMLTest(unittest.TestCase):
|
||||
"""This test suite takes a YAML configuration file and holds it against the syntax
|
||||
(Yamale) and semantic validators, returning errors in case of validation failures."""
|
||||
def __init__(self, testName, yaml_filename, yaml_schema):
|
||||
# calling the super class init varies for different python versions. This works for 2.7
|
||||
super().__init__(testName)
|
||||
@ -43,6 +46,7 @@ class YAMLTest(unittest.TestCase):
|
||||
self.yaml_schema = yaml_schema
|
||||
|
||||
def test_yaml(self):
|
||||
""" The test executor """
|
||||
test = None
|
||||
cfg = None
|
||||
ncount = 0
|
||||
@ -103,6 +107,7 @@ class YAMLTest(unittest.TestCase):
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
""" The main program """
|
||||
parser = argparse.ArgumentParser(formatter_class=argparse.RawTextHelpFormatter)
|
||||
parser.add_argument(
|
||||
"-t",
|
||||
|
Reference in New Issue
Block a user