craftbeerpi4-pione/venv3/lib/python3.7/site-packages/tests/test_cli.py
2021-03-03 23:49:41 +01:00

20 lines
No EOL
481 B
Python

import logging
import unittest
from cli import add, remove, list_plugins
logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(name)s - %(message)s')
class CLITest(unittest.TestCase):
def test_install(self):
assert add("cbpi4-ui-plugin") == True
assert add("cbpi4-ui-plugin") == False
assert remove("cbpi4-ui-plugin") == True
def test_list(self):
list_plugins()
if __name__ == '__main__':
unittest.main()