2019-09-18 13:28:46 +00:00
|
|
|
import os
|
|
|
|
|
|
|
|
import testinfra.utils.ansible_runner
|
|
|
|
|
2019-10-15 21:23:56 +00:00
|
|
|
import warnings
|
|
|
|
warnings.filterwarnings("ignore", category=DeprecationWarning)
|
|
|
|
|
2019-09-18 13:28:46 +00:00
|
|
|
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
|
|
|
|
os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all')
|
|
|
|
|
|
|
|
|
2019-10-15 21:23:56 +00:00
|
|
|
def test_certbot_is_installed(host):
|
|
|
|
certbot = host.package("certbot")
|
|
|
|
assert certbot.is_installed
|