tests/test_codingstype.py
cff5df80
 import unittest
 import subprocess
 import glob
 
 
 class TestCodingstyle(unittest.TestCase):
     @staticmethod
     def test_codingstyle():
e3346581
         pyfiles = ["freewvs", "update-freewvsdb",
                    "setup.py"] + glob.glob("tests/*.py")
cff5df80
         subprocess.run(["pycodestyle", "--ignore=W503"]
                        + pyfiles, check=True)
         subprocess.run(["pyflakes"] + pyfiles, check=True)
9b61bfcf
 
e3346581
         pylint_disable = "missing-docstring,invalid-name," \
                          + "too-many-arguments,duplicate-code"
9b61bfcf
         subprocess.run(["pylint", "--disable=%s" % pylint_disable]
cff5df80
                        + pyfiles, check=True)
 
1342c489
         subprocess.run(["flake8", "--select=DUO"] + pyfiles, check=True)
ffe185a9
         subprocess.run(["pyupgrade", "--keep-percent-format", "--py38-plus"]
                        + pyfiles, check=True)
1342c489
 
cff5df80
 
 if __name__ == '__main__':
     unittest.main()