From 545746b16a8c4b59eb850fb379986439a44b7a4e Mon Sep 17 00:00:00 2001 From: Robert Kaussow Date: Wed, 18 Sep 2019 13:19:23 +0200 Subject: [PATCH] add sbin to PATH to fix testinfra iptables module --- molecule/ec2-centos-7/tests/test_default.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/molecule/ec2-centos-7/tests/test_default.py b/molecule/ec2-centos-7/tests/test_default.py index 86313ed..d6af129 100644 --- a/molecule/ec2-centos-7/tests/test_default.py +++ b/molecule/ec2-centos-7/tests/test_default.py @@ -1,4 +1,5 @@ import os +import sys import testinfra.utils.ansible_runner @@ -8,6 +9,8 @@ warnings.filterwarnings("ignore", category=DeprecationWarning) testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner( os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all') +sys.path.append('/usr/sbin') + def test_iptables_is_installed(host): iptables = host.package("iptables")