6
0
mirror of https://github.com/ChristianLight/tutor.git synced 2025-01-22 13:18:24 +00:00
tutor/tests/test_scripts.py

15 lines
420 B
Python
Raw Normal View History

2019-05-11 20:41:04 +02:00
import unittest
import unittest.mock
from tutor import config as tutor_config
2019-05-11 20:41:04 +02: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"))