Loading tests/test_ntp.py +8 −3 Original line number Diff line number Diff line def test_ntp(Service, Ansible): if Ansible('setup')['ansible_facts']['ansible_service_mgr'] == 'systemd': assert Service('systemd-timesyncd').is_running service = Service('systemd-timesyncd') elif Ansible('setup')['ansible_facts']['ansible_os_family'] == 'Debian': assert Service('openntpd').is_running service = Service('openntpd') elif Ansible('setup')['ansible_facts']['ansible_os_family'] == 'OpenBSD': assert Service('ntpd').is_running service = Service('ntpd') assert service.is_running try: assert service.is_enabled except NotImplementedError: pass Loading
tests/test_ntp.py +8 −3 Original line number Diff line number Diff line def test_ntp(Service, Ansible): if Ansible('setup')['ansible_facts']['ansible_service_mgr'] == 'systemd': assert Service('systemd-timesyncd').is_running service = Service('systemd-timesyncd') elif Ansible('setup')['ansible_facts']['ansible_os_family'] == 'Debian': assert Service('openntpd').is_running service = Service('openntpd') elif Ansible('setup')['ansible_facts']['ansible_os_family'] == 'OpenBSD': assert Service('ntpd').is_running service = Service('ntpd') assert service.is_running try: assert service.is_enabled except NotImplementedError: pass