mirror of
https://github.com/dylanaraps/pywal.git
synced 2024-11-29 11:24:03 +01:00
commit
1f1c21e788
@ -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()
|
||||
|
Loading…
Reference in New Issue
Block a user