forked from pool/python-pytest-testinfra
* [FIX] Fix output of error message
* [FIX] Ansible: Fix for missing group names in get_variables()
* [FIX] testinfra/modules/blockdevice: Don't fail on stderr
* [DOC] Extend and show the documentation of CommandResult
* [FIX] Extend list of valid suffixes for systemd units
* [DOC] Add missing Environment doc section
* [MISC] Define types for plugin.py
* [MISC] Bump actions/checkout from 3 to 4
* [FIX] Missing RHEL distribution in package module
* [NEW] feat(package): brew support
* [NEW] Add Service.exists
* [MISC] Make CommandResult a dataclass
- update to 9.0.0:
* [BREAKING] pytest-testinfra now require python >= 3.9
* [BREAKING] Drop deprecated module PipPackage
* [NEW] Add support for the SSH ControlPath connection sharing
option
* [FIX] Retry SSH on ConnectionResetError
* [FIX] List openSUSE Leap and Tumbleweed explicitly as rpm
based distributions
* [FIX] Make group name mandatory in group module
to skip salt backend and still test the rest.
* Add arch (architecture) attribute to system_info module
* Add a new ansible connection options “force_ansible”, when set
to True, testinfra will always call ansible for all commands
* Handle all ansible connections types by setting force_ansible=True
for connections which doesn’t have a testinfra equivalent connection
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:pytest/python-pytest-testinfra?expand=0&rev=12
24 lines
1.0 KiB
Diff
24 lines
1.0 KiB
Diff
Index: pytest-testinfra-10.0.0/test/test_backends.py
|
|
===================================================================
|
|
--- pytest-testinfra-10.0.0.orig/test/test_backends.py
|
|
+++ pytest-testinfra-10.0.0/test/test_backends.py
|
|
@@ -476,13 +476,13 @@ def test_ansible_unknown_option():
|
|
with pytest.raises(KeyError, match="^'unknown'$"):
|
|
runner.options_to_cli({"unknown": True})
|
|
|
|
-
|
|
-def test_backend_importables():
|
|
+@pytest.mark.parametrize('connection_type',
|
|
+ testinfra.backend.BACKENDS.keys())
|
|
+def test_backend_importables(connection_type):
|
|
# just check that all declared backend are importable and NAME is set
|
|
# correctly
|
|
- for connection_type in testinfra.backend.BACKENDS:
|
|
- obj = testinfra.backend.get_backend_class(connection_type)
|
|
- assert obj.get_connection_type() == connection_type
|
|
+ obj = testinfra.backend.get_backend_class(connection_type)
|
|
+ assert obj.get_connection_type() == connection_type
|
|
|
|
|
|
@pytest.mark.testinfra_hosts("docker://rockylinux9", "ssh://rockylinux9")
|