/
githubmirror
/
salt
Обзор
Документация
Войти
/
githubmirror
/
salt
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
tests/integration/modules/test_chocolatey.py
33 строки
933 B
Charles McMarrow
[3006.x] rebase test labels (#64053)
16 апр 2023, 04:19
Не верифицирован
16 апр 2023, 04:19
8dc6dd6
Код
Авторство
О чём код?
import pytest import salt.utils.path import salt.utils.platform from tests.support.case import ModuleCase from tests.support.sminion import create_sminion @pytest.mark.skip_unless_on_windows @pytest.mark.windows_whitelisted @pytest.mark.destructive_test @pytest.mark.slow_test class ChocolateyModuleTest(ModuleCase): """ Validate Chocolatey module """ @classmethod def setUpClass(cls): """ Ensure that Chocolatey is installed """ if salt.utils.path.which("chocolatey.exe") is None: sminion = create_sminion() sminion.functions.chocolatey.bootstrap() def test_list_(self): ret = self.run_function("chocolatey.list", narrow="adobereader", exact=True) self.assertTrue("adobereader" in ret) def test_list_sources(self): ret = self.run_function("chocolatey.list_sources") self.assertTrue("chocolatey" in ret.keys())