def test_install(self): temp_folder = self.create_temp_folder() os.environ[CELERY_WORK_DIR_PATH_KEY] = temp_folder install_celery_plugin(plugin=self.plugins['plugin']) # check the plugin was installed from mock_for_test import module as m print m.var
def test_extract_module_paths(self): temp_folder = self.create_temp_folder() os.environ[CELERY_WORK_DIR_PATH_KEY] = temp_folder install_celery_plugin(self.plugins['plugin']) paths = extract_module_paths("mock-plugin") assert "mock_for_test.module" in paths
def test_install_with_dependencies(self): temp_folder = self.create_temp_folder() os.environ[CELERY_WORK_DIR_PATH_KEY] = temp_folder install_celery_plugin(plugin=self.plugins['plugin_with_dependencies']) # check the plugin was installed from mock_with_dependencies_for_test import module as m print m.var # check the dependency was installed from python_webserver_installer import tasks as t t.get_webserver_root