xoxys.lego/molecule/default/tests/test_default.py

14 lines
265 B
Python
Raw Normal View History

2024-09-27 18:40:51 +00:00
import os
import testinfra.utils.ansible_runner
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
os.environ["MOLECULE_INVENTORY_FILE"]
).get_hosts("all")
def test_lego_bin(host):
cmd = host.run("lego --version")
assert cmd.succeeded