6
0
mirror of https://github.com/ChristianLight/tutor.git synced 2024-12-12 14:17:46 +00:00
tutor/tests/test_scripts.py

15 lines
420 B
Python
Raw Normal View History

2019-05-11 18:41:04 +00:00
import unittest
import unittest.mock
from tutor import config as tutor_config
2019-05-11 18:41:04 +00:00
from tutor import scripts
class ScriptsTests(unittest.TestCase):
def test_is_activated(self):
config = {"ACTIVATE_SERVICE1": True, "ACTIVATE_SERVICE2": False}
runner = scripts.BaseRunner("/tmp", config)
self.assertTrue(runner.is_activated("service1"))
self.assertFalse(runner.is_activated("service2"))