summaryrefslogtreecommitdiff
path: root/tasks.py
diff options
context:
space:
mode:
authorTodd Leonhardt <todd.leonhardt@gmail.com>2018-06-11 10:37:47 -0400
committerGitHub <noreply@github.com>2018-06-11 10:37:47 -0400
commit44282fa49b2db9e4de7dc2f08e4d60e8b2be145f (patch)
tree8ceeddb81ff1a660e1ada5ba55f379968f23bfb6 /tasks.py
parent2565ae7832edfe42ee7631473f67a09b6789e679 (diff)
parent1bcf59856fae624e72153c631b94a1c7cca17d9e (diff)
downloadcmd2-git-44282fa49b2db9e4de7dc2f08e4d60e8b2be145f.tar.gz
Merge branch 'master' into type_hinting
Diffstat (limited to 'tasks.py')
-rw-r--r--tasks.py17
1 files changed, 16 insertions, 1 deletions
diff --git a/tasks.py b/tasks.py
index 5c0bd772..ac525517 100644
--- a/tasks.py
+++ b/tasks.py
@@ -49,11 +49,26 @@ namespace.add_task(pytest)
def pytest_clean(context):
"Remove pytest cache and code coverage files and directories"
#pylint: disable=unused-argument
- dirs = ['.pytest-cache', '.cache', 'htmlcov', '.coverage']
+ dirs = ['.pytest_cache', '.cache', 'htmlcov', '.coverage']
rmrf(dirs)
namespace_clean.add_task(pytest_clean, 'pytest')
@invoke.task
+def mypy(context):
+ "Run mypy optional static type checker"
+ context.run("mypy main.py")
+ namespace.add_task(mypy)
+namespace.add_task(mypy)
+
+@invoke.task
+def mypy_clean(context):
+ "Remove mypy cache directory"
+ #pylint: disable=unused-argument
+ dirs = ['.mypy_cache']
+ rmrf(dirs)
+namespace_clean.add_task(mypy_clean, 'mypy')
+
+@invoke.task
def tox(context):
"Run unit and integration tests on multiple python versions using tox"
context.run("tox")