From e4d499763c3233c6b0ff37989b6bb45d2f4aafa4 Mon Sep 17 00:00:00 2001 From: Rich Megginson Date: Tue, 19 Dec 2023 18:27:28 -0700 Subject: [PATCH] ci: Use supported ansible-lint action; run ansible-lint against the collection The old ansible-community ansible-lint is deprecated. There is a new ansible-lint github action. The new ansible-lint has several checks related to ansible-test and the ignore files. Many of our ignore settings are not allowed any more and are required to be fixed or addressed in the Ansible preferred way. The python imports have to be wrapped in a try/except ImportError, and where possible, an error must be returned from the module explaining what was not able to be imported. The module documentation must comply with the Ansible standards. One aspect of this is the `version_added` must be a valid ansible-core version in X.Y.Z format. Note that this version isn't really used anywhere, so it doesn't matter for users of the role, it is purely an `ansible-test` and import gating issue. The result of this is that the .sanity files can be reduced to the bare minimum which will greatly reduce the maintenance burden of those files, make it easier to support newer versions of Ansible, and make it easier to import the system roles collection into Galaxy and Automation Hub. The latest Ansible repo gating tests run ansible-lint against the collection format instead of against individual roles. We have to convert the role to collection format before running ansible-test. Role developers can run this locally using `tox -e collection,ansible-lint-collection` See https://github.com/linux-system-roles/tox-lsr/pull/125 Add `---` doc start to .markdownlint.yaml The file `examples/down_profile+delete_interface.yml` was not used and was causing ansible-lint errors. ansible-lint enforces the order of keywords in plays - `name`, then `hosts`, then `vars`, then `tasks`. Signed-off-by: Rich Megginson --- .markdownlint.yaml | 1 + .sanity-ansible-ignore-2.11.txt | 72 +------------------ .sanity-ansible-ignore-2.12.txt | 69 ------------------ .sanity-ansible-ignore-2.13.txt | 69 ------------------ .sanity-ansible-ignore-2.14.txt | 69 ------------------ .sanity-ansible-ignore-2.15.txt | 69 ------------------ .sanity-ansible-ignore-2.16.txt | 3 + .sanity-ansible-ignore-2.9.txt | 44 +----------- examples/down_profile+delete_interface.yml | 1 - library/network_connections.py | 51 +++++++++++-- library/network_state.py | 35 ++++++++- module_utils/network_lsr/nm/__init__.py | 11 --- module_utils/network_lsr/nm/client.py | 50 +++++++------ tests/ensure_provider_tests.py | 12 ++-- tests/playbooks/tests_switch_provider.yml | 4 +- tests/tests_802_1x_nm.yml | 6 +- tests/tests_802_1x_updated_nm.yml | 6 +- tests/tests_auto_gateway_initscripts.yml | 6 +- tests/tests_auto_gateway_nm.yml | 6 +- tests/tests_bond_cloned_mac_initscripts.yml | 6 +- tests/tests_bond_cloned_mac_nm.yml | 6 +- tests/tests_bond_deprecated_initscripts.yml | 6 +- tests/tests_bond_deprecated_nm.yml | 6 +- tests/tests_bond_initscripts.yml | 6 +- tests/tests_bond_nm.yml | 6 +- tests/tests_bond_options_nm.yml | 6 +- tests/tests_bond_removal_initscripts.yml | 6 +- tests/tests_bond_removal_nm.yml | 6 +- tests/tests_bridge_cloned_mac_initscripts.yml | 6 +- tests/tests_bridge_cloned_mac_nm.yml | 6 +- tests/tests_bridge_initscripts.yml | 6 +- tests/tests_bridge_nm.yml | 6 +- .../tests_change_indication_on_repeat_run.yml | 4 +- tests/tests_default_initscripts.yml | 4 +- tests/tests_default_nm.yml | 4 +- tests/tests_dummy_nm.yml | 6 +- tests/tests_eth_dns_support_nm.yml | 6 +- tests/tests_eth_pci_address_match_nm.yml | 6 +- tests/tests_ethernet_initscripts.yml | 6 +- tests/tests_ethernet_nm.yml | 6 +- tests/tests_ethtool_coalesce_initscripts.yml | 6 +- tests/tests_ethtool_coalesce_nm.yml | 6 +- tests/tests_ethtool_features_initscripts.yml | 6 +- tests/tests_ethtool_features_nm.yml | 6 +- tests/tests_ethtool_ring_initscripts.yml | 6 +- tests/tests_ethtool_ring_nm.yml | 6 +- tests/tests_ignore_auto_dns_nm.yml | 6 +- tests/tests_infiniband_nm.yml | 6 +- tests/tests_integration_pytest.yml | 4 +- tests/tests_ipv6_disabled_nm.yml | 6 +- tests/tests_ipv6_dns_search_nm.yml | 6 +- tests/tests_ipv6_initscripts.yml | 6 +- tests/tests_ipv6_nm.yml | 6 +- tests/tests_network_state_nm.yml | 6 +- tests/tests_provider_nm.yml | 6 +- tests/tests_reapply_nm.yml | 6 +- tests/tests_regression_nm.yml | 4 +- tests/tests_route_device_initscripts.yml | 6 +- tests/tests_route_device_nm.yml | 6 +- tests/tests_route_table_nm.yml | 6 +- tests/tests_routing_rules_nm.yml | 6 +- tests/tests_states_initscripts.yml | 6 +- tests/tests_states_nm.yml | 6 +- tests/tests_switch_provider.yml | 4 +- tests/tests_team_nm.yml | 6 +- tests/tests_team_plugin_installation_nm.yml | 6 +- tests/tests_unit.yml | 8 +-- tests/tests_vlan_mtu_initscripts.yml | 6 +- tests/tests_vlan_mtu_nm.yml | 6 +- tests/tests_wireless_nm.yml | 6 +- .../tests_wireless_plugin_installation_nm.yml | 6 +- tests/tests_wireless_wpa3_owe_nm.yml | 6 +- tests/tests_wireless_wpa3_sae_nm.yml | 6 +- 73 files changed, 288 insertions(+), 610 deletions(-) create mode 100644 .sanity-ansible-ignore-2.16.txt delete mode 120000 examples/down_profile+delete_interface.yml diff --git a/.markdownlint.yaml b/.markdownlint.yaml index 4f8a979..6bf4ccd 100644 --- a/.markdownlint.yaml +++ b/.markdownlint.yaml @@ -1,3 +1,4 @@ +--- # Default state for all rules default: true diff --git a/.sanity-ansible-ignore-2.11.txt b/.sanity-ansible-ignore-2.11.txt index 0400b31..5eff638 100644 --- a/.sanity-ansible-ignore-2.11.txt +++ b/.sanity-ansible-ignore-2.11.txt @@ -1,73 +1,3 @@ -plugins/module_utils/network_lsr/nm/__init__.py empty-init!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.5!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.8!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.9!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.10!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/client.py import-2.6!skip -plugins/module_utils/network_lsr/nm/client.py import-2.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.5!skip -plugins/module_utils/network_lsr/nm/client.py import-3.6!skip -plugins/module_utils/network_lsr/nm/client.py import-3.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.8!skip -plugins/module_utils/network_lsr/nm/client.py import-3.9!skip -plugins/module_utils/network_lsr/nm/client.py import-3.10!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/error.py import-2.6!skip -plugins/module_utils/network_lsr/nm/error.py import-2.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.5!skip -plugins/module_utils/network_lsr/nm/error.py import-3.6!skip -plugins/module_utils/network_lsr/nm/error.py import-3.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.8!skip -plugins/module_utils/network_lsr/nm/error.py import-3.9!skip -plugins/module_utils/network_lsr/nm/error.py import-3.10!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.5!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.8!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.9!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.10!skip -plugins/modules/network_connections.py validate-modules:doc-default-does-not-match-spec -plugins/modules/network_connections.py validate-modules:doc-required-mismatch -plugins/modules/network_connections.py validate-modules:missing-examples plugins/modules/network_connections.py validate-modules:missing-gplv3-license -plugins/modules/network_connections.py validate-modules:module-invalid-version-added -plugins/modules/network_connections.py validate-modules:no-default-for-required-parameter -plugins/modules/network_connections.py validate-modules:parameter-list-no-elements -plugins/modules/network_connections.py validate-modules:parameter-type-not-in-doc -plugins/modules/network_connections.py validate-modules:undocumented-parameter -tests/network/ensure_provider_tests.py compile-2.6!skip -tests/network/ensure_provider_tests.py compile-2.7!skip -tests/network/ensure_provider_tests.py compile-3.5!skip -tests/network/ensure_provider_tests.py future-import-boilerplate!skip -tests/network/ensure_provider_tests.py metaclass-boilerplate!skip +plugins/modules/network_state.py validate-modules:missing-gplv3-license tests/network/ensure_provider_tests.py shebang!skip -tests/network/integration/conftest.py future-import-boilerplate!skip -tests/network/integration/conftest.py metaclass-boilerplate!skip -tests/network/integration/test_ethernet.py future-import-boilerplate!skip -tests/network/integration/test_ethernet.py metaclass-boilerplate!skip -tests/network/merge_coverage.sh shebang!skip -tests/network/unit/test_network_connections.py future-import-boilerplate!skip -tests/network/unit/test_network_connections.py metaclass-boilerplate!skip -tests/network/unit/test_nm_provider.py future-import-boilerplate!skip -tests/network/unit/test_nm_provider.py metaclass-boilerplate!skip diff --git a/.sanity-ansible-ignore-2.12.txt b/.sanity-ansible-ignore-2.12.txt index 1c22c07..5eff638 100644 --- a/.sanity-ansible-ignore-2.12.txt +++ b/.sanity-ansible-ignore-2.12.txt @@ -1,72 +1,3 @@ -plugins/module_utils/network_lsr/nm/__init__.py empty-init!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.5!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.8!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.9!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.10!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/client.py import-2.6!skip -plugins/module_utils/network_lsr/nm/client.py import-2.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.5!skip -plugins/module_utils/network_lsr/nm/client.py import-3.6!skip -plugins/module_utils/network_lsr/nm/client.py import-3.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.8!skip -plugins/module_utils/network_lsr/nm/client.py import-3.9!skip -plugins/module_utils/network_lsr/nm/client.py import-3.10!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/error.py import-2.6!skip -plugins/module_utils/network_lsr/nm/error.py import-2.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.5!skip -plugins/module_utils/network_lsr/nm/error.py import-3.6!skip -plugins/module_utils/network_lsr/nm/error.py import-3.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.8!skip -plugins/module_utils/network_lsr/nm/error.py import-3.9!skip -plugins/module_utils/network_lsr/nm/error.py import-3.10!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.5!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.8!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.9!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.10!skip -plugins/modules/network_connections.py validate-modules:doc-default-does-not-match-spec -plugins/modules/network_connections.py validate-modules:doc-required-mismatch -plugins/modules/network_connections.py validate-modules:missing-examples plugins/modules/network_connections.py validate-modules:missing-gplv3-license -plugins/modules/network_connections.py validate-modules:module-invalid-version-added -plugins/modules/network_connections.py validate-modules:no-default-for-required-parameter -plugins/modules/network_connections.py validate-modules:parameter-list-no-elements -plugins/modules/network_connections.py validate-modules:parameter-type-not-in-doc -plugins/modules/network_connections.py validate-modules:undocumented-parameter -plugins/modules/network_state.py import-2.6!skip -plugins/modules/network_state.py import-2.7!skip -plugins/modules/network_state.py import-3.5!skip -plugins/modules/network_state.py import-3.6!skip -plugins/modules/network_state.py import-3.7!skip -plugins/modules/network_state.py import-3.8!skip -plugins/modules/network_state.py import-3.9!skip -plugins/modules/network_state.py import-3.10!skip -plugins/modules/network_state.py validate-modules:import-error -plugins/modules/network_state.py validate-modules:missing-examples plugins/modules/network_state.py validate-modules:missing-gplv3-license -plugins/modules/network_state.py validate-modules:module-invalid-version-added tests/network/ensure_provider_tests.py shebang!skip -tests/network/merge_coverage.sh shebang!skip diff --git a/.sanity-ansible-ignore-2.13.txt b/.sanity-ansible-ignore-2.13.txt index 1c22c07..5eff638 100644 --- a/.sanity-ansible-ignore-2.13.txt +++ b/.sanity-ansible-ignore-2.13.txt @@ -1,72 +1,3 @@ -plugins/module_utils/network_lsr/nm/__init__.py empty-init!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.5!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.8!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.9!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.10!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/client.py import-2.6!skip -plugins/module_utils/network_lsr/nm/client.py import-2.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.5!skip -plugins/module_utils/network_lsr/nm/client.py import-3.6!skip -plugins/module_utils/network_lsr/nm/client.py import-3.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.8!skip -plugins/module_utils/network_lsr/nm/client.py import-3.9!skip -plugins/module_utils/network_lsr/nm/client.py import-3.10!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/error.py import-2.6!skip -plugins/module_utils/network_lsr/nm/error.py import-2.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.5!skip -plugins/module_utils/network_lsr/nm/error.py import-3.6!skip -plugins/module_utils/network_lsr/nm/error.py import-3.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.8!skip -plugins/module_utils/network_lsr/nm/error.py import-3.9!skip -plugins/module_utils/network_lsr/nm/error.py import-3.10!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.5!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.8!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.9!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.10!skip -plugins/modules/network_connections.py validate-modules:doc-default-does-not-match-spec -plugins/modules/network_connections.py validate-modules:doc-required-mismatch -plugins/modules/network_connections.py validate-modules:missing-examples plugins/modules/network_connections.py validate-modules:missing-gplv3-license -plugins/modules/network_connections.py validate-modules:module-invalid-version-added -plugins/modules/network_connections.py validate-modules:no-default-for-required-parameter -plugins/modules/network_connections.py validate-modules:parameter-list-no-elements -plugins/modules/network_connections.py validate-modules:parameter-type-not-in-doc -plugins/modules/network_connections.py validate-modules:undocumented-parameter -plugins/modules/network_state.py import-2.6!skip -plugins/modules/network_state.py import-2.7!skip -plugins/modules/network_state.py import-3.5!skip -plugins/modules/network_state.py import-3.6!skip -plugins/modules/network_state.py import-3.7!skip -plugins/modules/network_state.py import-3.8!skip -plugins/modules/network_state.py import-3.9!skip -plugins/modules/network_state.py import-3.10!skip -plugins/modules/network_state.py validate-modules:import-error -plugins/modules/network_state.py validate-modules:missing-examples plugins/modules/network_state.py validate-modules:missing-gplv3-license -plugins/modules/network_state.py validate-modules:module-invalid-version-added tests/network/ensure_provider_tests.py shebang!skip -tests/network/merge_coverage.sh shebang!skip diff --git a/.sanity-ansible-ignore-2.14.txt b/.sanity-ansible-ignore-2.14.txt index 318c8d1..5eff638 100644 --- a/.sanity-ansible-ignore-2.14.txt +++ b/.sanity-ansible-ignore-2.14.txt @@ -1,72 +1,3 @@ -plugins/module_utils/network_lsr/nm/__init__.py empty-init!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.5!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.8!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.9!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.10!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.11!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.11!skip -plugins/module_utils/network_lsr/nm/client.py import-2.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.5!skip -plugins/module_utils/network_lsr/nm/client.py import-3.6!skip -plugins/module_utils/network_lsr/nm/client.py import-3.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.8!skip -plugins/module_utils/network_lsr/nm/client.py import-3.9!skip -plugins/module_utils/network_lsr/nm/client.py import-3.10!skip -plugins/module_utils/network_lsr/nm/client.py import-3.11!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.11!skip -plugins/module_utils/network_lsr/nm/error.py import-2.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.5!skip -plugins/module_utils/network_lsr/nm/error.py import-3.6!skip -plugins/module_utils/network_lsr/nm/error.py import-3.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.8!skip -plugins/module_utils/network_lsr/nm/error.py import-3.9!skip -plugins/module_utils/network_lsr/nm/error.py import-3.10!skip -plugins/module_utils/network_lsr/nm/error.py import-3.11!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.5!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.8!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.9!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.10!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.11!skip -plugins/modules/network_connections.py validate-modules:doc-default-does-not-match-spec -plugins/modules/network_connections.py validate-modules:doc-required-mismatch -plugins/modules/network_connections.py validate-modules:missing-examples plugins/modules/network_connections.py validate-modules:missing-gplv3-license -plugins/modules/network_connections.py validate-modules:module-invalid-version-added -plugins/modules/network_connections.py validate-modules:no-default-for-required-parameter -plugins/modules/network_connections.py validate-modules:parameter-list-no-elements -plugins/modules/network_connections.py validate-modules:parameter-type-not-in-doc -plugins/modules/network_connections.py validate-modules:undocumented-parameter -plugins/modules/network_state.py import-2.7!skip -plugins/modules/network_state.py import-3.5!skip -plugins/modules/network_state.py import-3.6!skip -plugins/modules/network_state.py import-3.7!skip -plugins/modules/network_state.py import-3.8!skip -plugins/modules/network_state.py import-3.9!skip -plugins/modules/network_state.py import-3.10!skip -plugins/modules/network_state.py import-3.11!skip -plugins/modules/network_state.py validate-modules:import-error -plugins/modules/network_state.py validate-modules:missing-examples plugins/modules/network_state.py validate-modules:missing-gplv3-license -plugins/modules/network_state.py validate-modules:module-invalid-version-added tests/network/ensure_provider_tests.py shebang!skip -tests/network/merge_coverage.sh shebang!skip diff --git a/.sanity-ansible-ignore-2.15.txt b/.sanity-ansible-ignore-2.15.txt index 318c8d1..5eff638 100644 --- a/.sanity-ansible-ignore-2.15.txt +++ b/.sanity-ansible-ignore-2.15.txt @@ -1,72 +1,3 @@ -plugins/module_utils/network_lsr/nm/__init__.py empty-init!skip -plugins/module_utils/network_lsr/nm/__init__.py import-2.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.5!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.6!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.7!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.8!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.9!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.10!skip -plugins/module_utils/network_lsr/nm/__init__.py import-3.11!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.11!skip -plugins/module_utils/network_lsr/nm/client.py import-2.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.5!skip -plugins/module_utils/network_lsr/nm/client.py import-3.6!skip -plugins/module_utils/network_lsr/nm/client.py import-3.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.8!skip -plugins/module_utils/network_lsr/nm/client.py import-3.9!skip -plugins/module_utils/network_lsr/nm/client.py import-3.10!skip -plugins/module_utils/network_lsr/nm/client.py import-3.11!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.9!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.10!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.11!skip -plugins/module_utils/network_lsr/nm/error.py import-2.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.5!skip -plugins/module_utils/network_lsr/nm/error.py import-3.6!skip -plugins/module_utils/network_lsr/nm/error.py import-3.7!skip -plugins/module_utils/network_lsr/nm/error.py import-3.8!skip -plugins/module_utils/network_lsr/nm/error.py import-3.9!skip -plugins/module_utils/network_lsr/nm/error.py import-3.10!skip -plugins/module_utils/network_lsr/nm/error.py import-3.11!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.5!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.8!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.9!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.10!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.11!skip -plugins/modules/network_connections.py validate-modules:doc-default-does-not-match-spec -plugins/modules/network_connections.py validate-modules:doc-required-mismatch -plugins/modules/network_connections.py validate-modules:missing-examples plugins/modules/network_connections.py validate-modules:missing-gplv3-license -plugins/modules/network_connections.py validate-modules:module-invalid-version-added -plugins/modules/network_connections.py validate-modules:no-default-for-required-parameter -plugins/modules/network_connections.py validate-modules:parameter-list-no-elements -plugins/modules/network_connections.py validate-modules:parameter-type-not-in-doc -plugins/modules/network_connections.py validate-modules:undocumented-parameter -plugins/modules/network_state.py import-2.7!skip -plugins/modules/network_state.py import-3.5!skip -plugins/modules/network_state.py import-3.6!skip -plugins/modules/network_state.py import-3.7!skip -plugins/modules/network_state.py import-3.8!skip -plugins/modules/network_state.py import-3.9!skip -plugins/modules/network_state.py import-3.10!skip -plugins/modules/network_state.py import-3.11!skip -plugins/modules/network_state.py validate-modules:import-error -plugins/modules/network_state.py validate-modules:missing-examples plugins/modules/network_state.py validate-modules:missing-gplv3-license -plugins/modules/network_state.py validate-modules:module-invalid-version-added tests/network/ensure_provider_tests.py shebang!skip -tests/network/merge_coverage.sh shebang!skip diff --git a/.sanity-ansible-ignore-2.16.txt b/.sanity-ansible-ignore-2.16.txt new file mode 100644 index 0000000..5eff638 --- /dev/null +++ b/.sanity-ansible-ignore-2.16.txt @@ -0,0 +1,3 @@ +plugins/modules/network_connections.py validate-modules:missing-gplv3-license +plugins/modules/network_state.py validate-modules:missing-gplv3-license +tests/network/ensure_provider_tests.py shebang!skip diff --git a/.sanity-ansible-ignore-2.9.txt b/.sanity-ansible-ignore-2.9.txt index f1713d4..5eff638 100644 --- a/.sanity-ansible-ignore-2.9.txt +++ b/.sanity-ansible-ignore-2.9.txt @@ -1,45 +1,3 @@ -plugins/module_utils/network_lsr/nm/__init__.py empty-init!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/active_connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/client.py import-2.6!skip -plugins/module_utils/network_lsr/nm/client.py import-2.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.5!skip -plugins/module_utils/network_lsr/nm/client.py import-3.6!skip -plugins/module_utils/network_lsr/nm/client.py import-3.7!skip -plugins/module_utils/network_lsr/nm/client.py import-3.8!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-2.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.5!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.6!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.7!skip -plugins/module_utils/network_lsr/nm/connection.py import-3.8!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-2.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.5!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.6!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.7!skip -plugins/module_utils/network_lsr/nm/provider.py import-3.8!skip -plugins/modules/network_connections.py validate-modules:missing-examples plugins/modules/network_connections.py validate-modules:missing-gplv3-license -plugins/modules/network_connections.py validate-modules:no-default-for-required-parameter -plugins/modules/network_connections.py validate-modules:parameter-type-not-in-doc -plugins/modules/network_connections.py validate-modules:undocumented-parameter -tests/network/ensure_provider_tests.py compile-2.6!skip -tests/network/ensure_provider_tests.py compile-2.7!skip -tests/network/ensure_provider_tests.py compile-3.5!skip -tests/network/ensure_provider_tests.py future-import-boilerplate!skip -tests/network/ensure_provider_tests.py metaclass-boilerplate!skip +plugins/modules/network_state.py validate-modules:missing-gplv3-license tests/network/ensure_provider_tests.py shebang!skip -tests/network/integration/conftest.py future-import-boilerplate!skip -tests/network/integration/conftest.py metaclass-boilerplate!skip -tests/network/integration/test_ethernet.py future-import-boilerplate!skip -tests/network/integration/test_ethernet.py metaclass-boilerplate!skip -tests/network/merge_coverage.sh shebang!skip -tests/network/unit/test_network_connections.py future-import-boilerplate!skip -tests/network/unit/test_network_connections.py metaclass-boilerplate!skip -tests/network/unit/test_nm_provider.py future-import-boilerplate!skip -tests/network/unit/test_nm_provider.py metaclass-boilerplate!skip diff --git a/examples/down_profile+delete_interface.yml b/examples/down_profile+delete_interface.yml deleted file mode 120000 index cbd4da1..0000000 --- a/examples/down_profile+delete_interface.yml +++ /dev/null @@ -1 +0,0 @@ -../tests/playbooks/down_profile+delete_interface.yml \ No newline at end of file diff --git a/library/network_connections.py b/library/network_connections.py index 07b29cc..43915c9 100644 --- a/library/network_connections.py +++ b/library/network_connections.py @@ -12,7 +12,7 @@ module: network_connections author: Thomas Haller (@thom311) short_description: module for network role to manage connection profiles requirements: [pygobject, dbus, NetworkManager] -version_added: "2.0" +version_added: "2.13.0" description: - "WARNING: Do not use this module directly! It is only for role internal use." - | @@ -22,9 +22,44 @@ description: role and currently it is not expected to use this module outside the role. Thus, consult README.md for examples for the role. The requirements are only for the NetworkManager (nm) provider. -options: {} +options: + __debug_flags: + description: Flags to use for debugging + required: false + type: str + default: '' + force_state_change: + description: Force a state change + required: false + type: bool + default: False + ignore_errors: + description: Ignore errors + required: false + type: bool + default: False + __header: + description: Header to use in generated files + required: true + type: str + provider: + description: Network provider to use - initscripts or nm + required: true + type: str + connections: + description: Network configuration options + required: false + default: [] + type: list + elements: dict """ +EXAMPLES = """ +network_connections: + connections: + - name: eth0 + state: up +""" import errno import functools @@ -1454,7 +1489,6 @@ class NMUtil: ) def connection_activate(self, connection, timeout=15, wait_time=None): - already_retried = False while True: @@ -1681,9 +1715,14 @@ class RunEnvironmentAnsible(RunEnvironment): ARGS = { "ignore_errors": {"required": False, "default": False, "type": "bool"}, "force_state_change": {"required": False, "default": False, "type": "bool"}, - "provider": {"required": True, "default": None, "type": "str"}, - "connections": {"required": False, "default": None, "type": "list"}, - "__header": {"required": True, "default": None, "type": "str"}, + "provider": {"required": True, "type": "str"}, + "connections": { + "required": False, + "default": [], + "type": "list", + "elements": "dict", + }, + "__header": {"required": True, "type": "str"}, "__debug_flags": {"required": False, "default": "", "type": "str"}, } diff --git a/library/network_state.py b/library/network_state.py index 3f88f79..1a44910 100644 --- a/library/network_state.py +++ b/library/network_state.py @@ -9,7 +9,7 @@ __metaclass__ = type DOCUMENTATION = r""" --- module: network_state -version_added: "2.9" +version_added: "2.13.0" short_description: module for network role to apply network state configuration description: - This module allows to apply the network state configuration through nmstate, @@ -22,6 +22,19 @@ options: author: "Wen Liang (@liangwen12year)" """ +EXAMPLES = r""" +network_state: + desired_state: + dns-resolver: + config: + search: + - example.com + - example.org + server: + - 2001:4860:4860::8888 + - 8.8.8.8 +""" + RETURN = r""" state: description: Network state after running the module @@ -29,8 +42,18 @@ state: returned: always """ -from ansible.module_utils.basic import AnsibleModule -import libnmstate # pylint: disable=import-error +import traceback + +from ansible.module_utils.basic import AnsibleModule, missing_required_lib + +try: + import libnmstate # pylint: disable=import-error +except ImportError: + NETWORK_HAS_NMSTATE = False + NETWORK_NMSTATE_IMPORT_ERROR = traceback.format_exc() +else: + NETWORK_HAS_NMSTATE = True + NETWORK_NMSTATE_IMPORT_ERROR = None class NetworkState: @@ -71,6 +94,12 @@ def run_module(): argument_spec=module_args, ) + if not NETWORK_HAS_NMSTATE: + module.fail_json( + msg=missing_required_lib("libnmstate"), + exception=NETWORK_NMSTATE_IMPORT_ERROR, + ) + network_state_module = NetworkState(module, "network_state") network_state_module.run() diff --git a/module_utils/network_lsr/nm/__init__.py b/module_utils/network_lsr/nm/__init__.py index 74c17cb..e69de29 100644 --- a/module_utils/network_lsr/nm/__init__.py +++ b/module_utils/network_lsr/nm/__init__.py @@ -1,11 +0,0 @@ -# Relative import is not support by ansible 2.8 yet -# pylint: disable=import-error, no-name-in-module -from __future__ import absolute_import, division, print_function - -__metaclass__ = type - -from ansible.module_utils.network_lsr.nm import provider # noqa:E501 - -# pylint: enable=import-error, no-name-in-module - -provider.NetworkManagerProvider diff --git a/module_utils/network_lsr/nm/client.py b/module_utils/network_lsr/nm/client.py index f47cc53..2327c76 100644 --- a/module_utils/network_lsr/nm/client.py +++ b/module_utils/network_lsr/nm/client.py @@ -10,32 +10,38 @@ import logging # pylint: disable=import-error, no-name-in-module from ansible.module_utils.network_lsr.nm import error # noqa:E501 -import gi - try: - gi.require_version("NM", "1.0") + import gi +except ImportError: + NETWORK_HAS_GI = False +else: + NETWORK_HAS_GI = True - # It is required to state the NM version before importing it - # But this break the flake8 rule: https://www.flake8rules.com/rules/E402.html - # Use NOQA: E402 to suppress it. - from gi.repository import NM # NOQA: E402 - from gi.repository import GLib # NOQA: E402 - from gi.repository import Gio # NOQA: E402 +if NETWORK_HAS_GI: + try: + gi.require_version("NM", "1.0") - # pylint: enable=import-error, no-name-in-module + # It is required to state the NM version before importing it + # But this break the flake8 rule: https://www.flake8rules.com/rules/E402.html + # Use NOQA: E402 to suppress it. + from gi.repository import NM # NOQA: E402 + from gi.repository import GLib # NOQA: E402 + from gi.repository import Gio # NOQA: E402 - NM - GLib - Gio -except ValueError: - # This is to workaround a bug in ansible 2.9 which causes - # this code to be executed on the control node, where NM - # is not guaranteed to exist. On the other hand, it is - # ensured on the managed nodes as NM package is installed - # in the network role. Therefore, this exception handling - # does not affect the network installation and configuration - # on the managed nodes. - pass + # pylint: enable=import-error, no-name-in-module + + NM + GLib + Gio + except ValueError: + # This is to workaround a bug in ansible 2.9 which causes + # this code to be executed on the control node, where NM + # is not guaranteed to exist. On the other hand, it is + # ensured on the managed nodes as NM package is installed + # in the network role. Therefore, this exception handling + # does not affect the network installation and configuration + # on the managed nodes. + pass def get_client(): diff --git a/tests/ensure_provider_tests.py b/tests/ensure_provider_tests.py index 95d4a06..bd52cd3 100755 --- a/tests/ensure_provider_tests.py +++ b/tests/ensure_provider_tests.py @@ -41,9 +41,9 @@ RUN_PLAYBOOK_WITH_NM = """# SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook '{test_playbook}' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook '{test_playbook}' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml @@ -149,9 +149,9 @@ IGNORE = [ RUN_PLAYBOOK_WITH_INITSCRIPTS = """# SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook '{test_playbook}' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook '{test_playbook}' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/playbooks/tests_switch_provider.yml b/tests/playbooks/tests_switch_provider.yml index 67cbda4..42faca9 100644 --- a/tests/playbooks/tests_switch_provider.yml +++ b/tests/playbooks/tests_switch_provider.yml @@ -2,8 +2,8 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - name: Switch initscripts provider to nm +- name: Switch initscripts provider to nm + hosts: all tasks: - name: Set fact to use initscripts network_provider set_fact: diff --git a/tests/tests_802_1x_nm.yml b/tests/tests_802_1x_nm.yml index 27e8606..043371a 100644 --- a/tests/tests_802_1x_nm.yml +++ b/tests/tests_802_1x_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_802_1x.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_802_1x.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_802_1x_updated_nm.yml b/tests/tests_802_1x_updated_nm.yml index 8b1d54c..03c8826 100644 --- a/tests/tests_802_1x_updated_nm.yml +++ b/tests/tests_802_1x_updated_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_802_1x_updated.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_802_1x_updated.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_auto_gateway_initscripts.yml b/tests/tests_auto_gateway_initscripts.yml index 273fb63..5309e2b 100644 --- a/tests/tests_auto_gateway_initscripts.yml +++ b/tests/tests_auto_gateway_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_auto_gateway.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_auto_gateway.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_auto_gateway_nm.yml b/tests/tests_auto_gateway_nm.yml index 39b629e..2be588d 100644 --- a/tests/tests_auto_gateway_nm.yml +++ b/tests/tests_auto_gateway_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_auto_gateway.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_auto_gateway.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_cloned_mac_initscripts.yml b/tests/tests_bond_cloned_mac_initscripts.yml index d464ed2..582aeb1 100644 --- a/tests/tests_bond_cloned_mac_initscripts.yml +++ b/tests/tests_bond_cloned_mac_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_cloned_mac.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_cloned_mac.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_cloned_mac_nm.yml b/tests/tests_bond_cloned_mac_nm.yml index d21c68d..01af653 100644 --- a/tests/tests_bond_cloned_mac_nm.yml +++ b/tests/tests_bond_cloned_mac_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_cloned_mac.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_cloned_mac.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_deprecated_initscripts.yml b/tests/tests_bond_deprecated_initscripts.yml index 9d052a2..85c5e64 100644 --- a/tests/tests_bond_deprecated_initscripts.yml +++ b/tests/tests_bond_deprecated_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_deprecated.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_deprecated.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_deprecated_nm.yml b/tests/tests_bond_deprecated_nm.yml index 28922b4..25d2f92 100644 --- a/tests/tests_bond_deprecated_nm.yml +++ b/tests/tests_bond_deprecated_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_deprecated.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_deprecated.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_initscripts.yml b/tests/tests_bond_initscripts.yml index 86b2a74..935d98e 100644 --- a/tests/tests_bond_initscripts.yml +++ b/tests/tests_bond_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_nm.yml b/tests/tests_bond_nm.yml index 2574150..d4b1a1b 100644 --- a/tests/tests_bond_nm.yml +++ b/tests/tests_bond_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_options_nm.yml b/tests/tests_bond_options_nm.yml index e215190..b59c7c1 100644 --- a/tests/tests_bond_options_nm.yml +++ b/tests/tests_bond_options_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_options.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_options.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_removal_initscripts.yml b/tests/tests_bond_removal_initscripts.yml index bed7dee..176ca95 100644 --- a/tests/tests_bond_removal_initscripts.yml +++ b/tests/tests_bond_removal_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_removal.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_removal.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bond_removal_nm.yml b/tests/tests_bond_removal_nm.yml index f4bf1d1..2d49280 100644 --- a/tests/tests_bond_removal_nm.yml +++ b/tests/tests_bond_removal_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bond_removal.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bond_removal.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bridge_cloned_mac_initscripts.yml b/tests/tests_bridge_cloned_mac_initscripts.yml index 7920330..fa79a07 100644 --- a/tests/tests_bridge_cloned_mac_initscripts.yml +++ b/tests/tests_bridge_cloned_mac_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bridge_cloned_mac.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bridge_cloned_mac.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bridge_cloned_mac_nm.yml b/tests/tests_bridge_cloned_mac_nm.yml index 40c7dfd..86db05d 100644 --- a/tests/tests_bridge_cloned_mac_nm.yml +++ b/tests/tests_bridge_cloned_mac_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bridge_cloned_mac.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bridge_cloned_mac.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bridge_initscripts.yml b/tests/tests_bridge_initscripts.yml index 6e5cef3..e74ac6b 100644 --- a/tests/tests_bridge_initscripts.yml +++ b/tests/tests_bridge_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bridge.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bridge.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_bridge_nm.yml b/tests/tests_bridge_nm.yml index a16e92e..53af046 100644 --- a/tests/tests_bridge_nm.yml +++ b/tests/tests_bridge_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_bridge.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_bridge.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_change_indication_on_repeat_run.yml b/tests/tests_change_indication_on_repeat_run.yml index 62c9312..41f564a 100644 --- a/tests/tests_change_indication_on_repeat_run.yml +++ b/tests/tests_change_indication_on_repeat_run.yml @@ -1,11 +1,11 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all +- name: Test change indication on repeat run + hosts: all vars: interface: testnic1 type: veth - name: Test change indication on repeat run tasks: - name: Determine if system is ostree and set flag when: not __network_is_ostree is defined diff --git a/tests/tests_default_initscripts.yml b/tests/tests_default_initscripts.yml index aee70a6..560bd2a 100644 --- a/tests/tests_default_initscripts.yml +++ b/tests/tests_default_initscripts.yml @@ -1,7 +1,7 @@ # SPDX-License-Identifier: BSD-3-Clause --- -- hosts: all - name: Run playbook 'tests_default.yml' with initscripts as provider +- name: Run playbook 'tests_default.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_default_nm.yml b/tests/tests_default_nm.yml index 22f4150..317f6e3 100644 --- a/tests/tests_default_nm.yml +++ b/tests/tests_default_nm.yml @@ -1,7 +1,7 @@ # SPDX-License-Identifier: BSD-3-Clause --- -- hosts: all - name: Run playbook 'tests_default.yml' with nm as provider +- name: Run playbook 'tests_default.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_dummy_nm.yml b/tests/tests_dummy_nm.yml index c67780e..c671200 100644 --- a/tests/tests_dummy_nm.yml +++ b/tests/tests_dummy_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_dummy.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_dummy.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_eth_dns_support_nm.yml b/tests/tests_eth_dns_support_nm.yml index eae3a64..682a7db 100644 --- a/tests/tests_eth_dns_support_nm.yml +++ b/tests/tests_eth_dns_support_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_eth_dns_support.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_eth_dns_support.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_eth_pci_address_match_nm.yml b/tests/tests_eth_pci_address_match_nm.yml index 84f0247..5277804 100644 --- a/tests/tests_eth_pci_address_match_nm.yml +++ b/tests/tests_eth_pci_address_match_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_eth_pci_address_match.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_eth_pci_address_match.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethernet_initscripts.yml b/tests/tests_ethernet_initscripts.yml index bbd4880..51de169 100644 --- a/tests/tests_ethernet_initscripts.yml +++ b/tests/tests_ethernet_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethernet.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethernet.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethernet_nm.yml b/tests/tests_ethernet_nm.yml index 86b51fd..4d534a7 100644 --- a/tests/tests_ethernet_nm.yml +++ b/tests/tests_ethernet_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethernet.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethernet.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethtool_coalesce_initscripts.yml b/tests/tests_ethtool_coalesce_initscripts.yml index 3e5aff8..198f30b 100644 --- a/tests/tests_ethtool_coalesce_initscripts.yml +++ b/tests/tests_ethtool_coalesce_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethtool_coalesce.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethtool_coalesce.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethtool_coalesce_nm.yml b/tests/tests_ethtool_coalesce_nm.yml index dd37ad0..595e8f6 100644 --- a/tests/tests_ethtool_coalesce_nm.yml +++ b/tests/tests_ethtool_coalesce_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethtool_coalesce.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethtool_coalesce.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethtool_features_initscripts.yml b/tests/tests_ethtool_features_initscripts.yml index d441dbf..fa3e714 100644 --- a/tests/tests_ethtool_features_initscripts.yml +++ b/tests/tests_ethtool_features_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethtool_features.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethtool_features.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethtool_features_nm.yml b/tests/tests_ethtool_features_nm.yml index 42d78c0..74c0fe1 100644 --- a/tests/tests_ethtool_features_nm.yml +++ b/tests/tests_ethtool_features_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethtool_features.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethtool_features.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethtool_ring_initscripts.yml b/tests/tests_ethtool_ring_initscripts.yml index 92b35b9..f317817 100644 --- a/tests/tests_ethtool_ring_initscripts.yml +++ b/tests/tests_ethtool_ring_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethtool_ring.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethtool_ring.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ethtool_ring_nm.yml b/tests/tests_ethtool_ring_nm.yml index 27df87d..e1b264c 100644 --- a/tests/tests_ethtool_ring_nm.yml +++ b/tests/tests_ethtool_ring_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ethtool_ring.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ethtool_ring.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ignore_auto_dns_nm.yml b/tests/tests_ignore_auto_dns_nm.yml index 7a1f799..aa07f0c 100644 --- a/tests/tests_ignore_auto_dns_nm.yml +++ b/tests/tests_ignore_auto_dns_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ignore_auto_dns.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ignore_auto_dns.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_infiniband_nm.yml b/tests/tests_infiniband_nm.yml index 0907414..619082a 100644 --- a/tests/tests_infiniband_nm.yml +++ b/tests/tests_infiniband_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_infiniband.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_infiniband.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_integration_pytest.yml b/tests/tests_integration_pytest.yml index c07465e..c26f65b 100644 --- a/tests/tests_integration_pytest.yml +++ b/tests/tests_integration_pytest.yml @@ -1,7 +1,7 @@ # SPDX-License-Identifier: BSD-3-Clause --- -- hosts: all - name: Run playbook 'playbooks/integration_pytest_python3.yml' +- name: Run playbook 'playbooks/integration_pytest_python3.yml' + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ipv6_disabled_nm.yml b/tests/tests_ipv6_disabled_nm.yml index b222b69..ced38f7 100644 --- a/tests/tests_ipv6_disabled_nm.yml +++ b/tests/tests_ipv6_disabled_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ipv6_disabled.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ipv6_disabled.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ipv6_dns_search_nm.yml b/tests/tests_ipv6_dns_search_nm.yml index 983ff57..f701da1 100644 --- a/tests/tests_ipv6_dns_search_nm.yml +++ b/tests/tests_ipv6_dns_search_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ipv6_dns_search.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ipv6_dns_search.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ipv6_initscripts.yml b/tests/tests_ipv6_initscripts.yml index 13e71b9..0e37cfe 100644 --- a/tests/tests_ipv6_initscripts.yml +++ b/tests/tests_ipv6_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ipv6.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ipv6.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_ipv6_nm.yml b/tests/tests_ipv6_nm.yml index bbff13e..bebd832 100644 --- a/tests/tests_ipv6_nm.yml +++ b/tests/tests_ipv6_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_ipv6.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_ipv6.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_network_state_nm.yml b/tests/tests_network_state_nm.yml index bb6b302..0e88282 100644 --- a/tests/tests_network_state_nm.yml +++ b/tests/tests_network_state_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_network_state.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_network_state.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_provider_nm.yml b/tests/tests_provider_nm.yml index 3031e0d..c8c5de1 100644 --- a/tests/tests_provider_nm.yml +++ b/tests/tests_provider_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_provider.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_provider.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_reapply_nm.yml b/tests/tests_reapply_nm.yml index 51fd51e..015c8f4 100644 --- a/tests/tests_reapply_nm.yml +++ b/tests/tests_reapply_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_reapply.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_reapply.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_regression_nm.yml b/tests/tests_regression_nm.yml index 6910550..5ff8550 100644 --- a/tests/tests_regression_nm.yml +++ b/tests/tests_regression_nm.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause --- # set network provider and gather facts -- hosts: all - name: Run playbook 'playbooks/tests_checkpoint_cleanup.yml' with nm as +- name: Run playbook 'playbooks/tests_checkpoint_cleanup.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_route_device_initscripts.yml b/tests/tests_route_device_initscripts.yml index 9a7df39..2bcc50c 100644 --- a/tests/tests_route_device_initscripts.yml +++ b/tests/tests_route_device_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_route_device.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_route_device.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_route_device_nm.yml b/tests/tests_route_device_nm.yml index 029adfa..46c3723 100644 --- a/tests/tests_route_device_nm.yml +++ b/tests/tests_route_device_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_route_device.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_route_device.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_route_table_nm.yml b/tests/tests_route_table_nm.yml index 915ae1f..239b010 100644 --- a/tests/tests_route_table_nm.yml +++ b/tests/tests_route_table_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_route_table.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_route_table.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_routing_rules_nm.yml b/tests/tests_routing_rules_nm.yml index 56639c3..b362207 100644 --- a/tests/tests_routing_rules_nm.yml +++ b/tests/tests_routing_rules_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_routing_rules.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_routing_rules.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_states_initscripts.yml b/tests/tests_states_initscripts.yml index 748d8d4..fd9da21 100644 --- a/tests/tests_states_initscripts.yml +++ b/tests/tests_states_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_states.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_states.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_states_nm.yml b/tests/tests_states_nm.yml index 7ca84bc..53729d1 100644 --- a/tests/tests_states_nm.yml +++ b/tests/tests_states_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_states.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_states.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_switch_provider.yml b/tests/tests_switch_provider.yml index fd2ad7e..5e90786 100644 --- a/tests/tests_switch_provider.yml +++ b/tests/tests_switch_provider.yml @@ -1,7 +1,7 @@ # SPDX-License-Identifier: BSD-3-Clause --- -- hosts: all - name: Run playbook 'playbooks/tests_switch_provider.yml' +- name: Run playbook 'playbooks/tests_switch_provider.yml' + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_team_nm.yml b/tests/tests_team_nm.yml index e2e14b0..bc60498 100644 --- a/tests/tests_team_nm.yml +++ b/tests/tests_team_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_team.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_team.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_team_plugin_installation_nm.yml b/tests/tests_team_plugin_installation_nm.yml index a0c7eec..46b3801 100644 --- a/tests/tests_team_plugin_installation_nm.yml +++ b/tests/tests_team_plugin_installation_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_team_plugin_installation.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_team_plugin_installation.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_unit.yml b/tests/tests_unit.yml index 1f29665..44a4df3 100644 --- a/tests/tests_unit.yml +++ b/tests/tests_unit.yml @@ -1,7 +1,7 @@ # SPDX-License-Identifier: BSD-3-Clause --- -- hosts: all - name: Setup for test running +- name: Setup for test running + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml @@ -21,8 +21,8 @@ - python-gobject-base - python2-mock -- hosts: all - name: Execute python unit tests +- name: Execute python unit tests + hosts: all tasks: - name: Execute python unit tests block: diff --git a/tests/tests_vlan_mtu_initscripts.yml b/tests/tests_vlan_mtu_initscripts.yml index 5a4719e..03f336e 100644 --- a/tests/tests_vlan_mtu_initscripts.yml +++ b/tests/tests_vlan_mtu_initscripts.yml @@ -1,9 +1,9 @@ # SPDX-License-Identifier: BSD-3-Clause # This file was generated by ensure_provider_tests.py --- -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_vlan_mtu.yml' with initscripts as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_vlan_mtu.yml' with initscripts as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_vlan_mtu_nm.yml b/tests/tests_vlan_mtu_nm.yml index 26251d1..bd648f0 100644 --- a/tests/tests_vlan_mtu_nm.yml +++ b/tests/tests_vlan_mtu_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_vlan_mtu.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_vlan_mtu.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_wireless_nm.yml b/tests/tests_wireless_nm.yml index 58cd8cd..495eee8 100644 --- a/tests/tests_wireless_nm.yml +++ b/tests/tests_wireless_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_wireless.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_wireless.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_wireless_plugin_installation_nm.yml b/tests/tests_wireless_plugin_installation_nm.yml index b9e0a2f..b24dbce 100644 --- a/tests/tests_wireless_plugin_installation_nm.yml +++ b/tests/tests_wireless_plugin_installation_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_wireless_plugin_installation.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_wireless_plugin_installation.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_wireless_wpa3_owe_nm.yml b/tests/tests_wireless_wpa3_owe_nm.yml index a928cc6..148f092 100644 --- a/tests/tests_wireless_wpa3_owe_nm.yml +++ b/tests/tests_wireless_wpa3_owe_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_wireless_wpa3_owe.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_wireless_wpa3_owe.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml diff --git a/tests/tests_wireless_wpa3_sae_nm.yml b/tests/tests_wireless_wpa3_sae_nm.yml index 6804127..1fd9bdb 100644 --- a/tests/tests_wireless_wpa3_sae_nm.yml +++ b/tests/tests_wireless_wpa3_sae_nm.yml @@ -2,9 +2,9 @@ # This file was generated by ensure_provider_tests.py --- # set network provider and gather facts -- hosts: all - # yamllint disable rule:line-length - name: Run playbook 'playbooks/tests_wireless_wpa3_sae.yml' with nm as provider +# yamllint disable rule:line-length +- name: Run playbook 'playbooks/tests_wireless_wpa3_sae.yml' with nm as provider + hosts: all tasks: - name: Include the task 'el_repo_setup.yml' include_tasks: tasks/el_repo_setup.yml