You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(molecule_test) $ molecule verify
WARNING:vagrant:The Vagrant executable cannot be found. Please check if it is in the system path.
--> Executing testinfra tests found in tests/.
============================= test session starts ==============================
platform linux2 -- Python 2.7.5, pytest-3.0.0, py-1.4.31, pluggy-0.3.1
rootdir: /git/ansible/ansible-zabbix-proxy, inifile:
plugins: cov-2.3.1, xdist-1.14, testinfra-1.4.1
collected 0 items / 1 errorss
==================================== ERRORS ====================================
____________________ ERROR collecting tests/test_default.py ____________________
/usr/lib/python2.7/site-packages/testinfra/plugin.py:124: in pytest_generate_tests
ansible_inventory=metafunc.config.option.ansible_inventory,
/usr/lib/python2.7/site-packages/testinfra/__init__.py:35: in get_backends
_BACKENDS_CACHE[key] = backend.get_backends(hosts, **kwargs)
/usr/lib/python2.7/site-packages/testinfra/backend/__init__.py:87: in get_backends
for name in klass.get_hosts(host, **kw):
/usr/lib/python2.7/site-packages/testinfra/backend/base.py:126: in get_hosts
cls.get_connection_type(),),
E RuntimeError: One or more hosts is required with the docker backend
============================ pytest-warning summary ============================
WP1 None Modules are already imported so can not be re-written: testinfra
!!!!!!!!!!!!!!!!!!! Interrupted: 1 errors during collection !!!!!!!!!!!!!!!!!!!!
================== 1 pytest-warnings, 1 error in 0.27 seconds ==================
ERROR:
RAN: '/usr/bin/testinfra tests/test_default.py --connection=docker'
STDOUT:
STDERR:
Molecule: 1.9.0
Ansible: 2.1.1.0
TestInfra: 1.4.1
Running testinfra manually does work.
The text was updated successfully, but these errors were encountered:
For those which run molecule init under 1.9 the test files will be created properly. Unfortunately, your tests were created with an older version of testinfra. I didn't think of the repercussions appropriately with this change.
Updating your tests with this, will fix your problem.
When doing an
molecule verify
with TestInfra:Molecule: 1.9.0
Ansible: 2.1.1.0
TestInfra: 1.4.1
Running testinfra manually does work.
The text was updated successfully, but these errors were encountered: