diff options
| author | Dylan Araps <dylanaraps@users.noreply.github.com> | 2017-08-03 15:12:45 +1000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-08-03 15:12:45 +1000 |
| commit | 1f1c21e78893d958d054bc0bb3887a40a8479507 (patch) | |
| tree | 1561aa091cb3a99d34333b873e9572eaec314912 | |
| parent | 60cbbe92b5c57dbba4282c9393ac27e32bc475b6 (diff) | |
| parent | f2f0769d70930533c9fffaf7bbb9adba477ef466 (diff) | |
Merge pull request #73 from aeikenberry/master
Adds test for -e
| -rw-r--r-- | tests/test_main.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/test_main.py b/tests/test_main.py index 4dbe580..9262c8f 100644 --- a/tests/test_main.py +++ b/tests/test_main.py @@ -1,7 +1,9 @@ """Test __main__ functions.""" import unittest +from unittest.mock import MagicMock from pywal import __main__ +from pywal import reload from pywal.settings import CACHE_DIR @@ -14,6 +16,13 @@ class TestMain(unittest.TestCase): __main__.process_args(args) self.assertFalse((CACHE_DIR / "schemes").is_dir()) + def test_args_e(self): + """> Test arg parsing (-e)""" + reload.env = MagicMock() + args = __main__.get_args(["-e"]) + __main__.process_args(args) + self.assertFalse(reload.env.called) + if __name__ == "__main__": unittest.main() |
