diff --git a/.travis.yml b/.travis.yml index 286243c..5f6df0e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,10 @@ install: - "pip install -r requirements.dev.txt" script: + # Run the test suit - nosetests --with-coverage --cover-package=stegano + # Run the type checker + - python tools/run_mypy.py after_success: - coveralls diff --git a/tools/run_mypy.py b/tools/run_mypy.py new file mode 100644 index 0000000..c70e6da --- /dev/null +++ b/tools/run_mypy.py @@ -0,0 +1,18 @@ +import subprocess +import sys + +modules = ["stegano/tools.py", + "stegano/lsb/lsb.py", + "stegano/lsbset/lsbset.py", + "stegano/lsbset/generators.py", + "stegano/red/red.py", + "stegano/exifHeader/exifHeader.py", + "stegano/steganalysis/parity.py", + "stegano/steganalysis/statistics.py"] + +exit_codes = [] +for module in modules: + rc = subprocess.call(["mypy", "--ignore-missing-imports", + "--follow-imports", "skip", module]) + exit_codes.append(rc) +sys.exit(max(exit_codes))