network/tests/playbooks
Noriko Hosoi 79b39792e4 System Roles should consistently use ansible_managed in configuration files it manages
bz#2044640

The network role create an ifcfg file for initscripts. The file
used to append a comment "# this file was created by ansible".
This patch replaces the proprietary string with the ansible
standard {{ ansible_managed }} to adjust to the other system
roles.

For the implementation, it borrowed the method from kernel_settings,
getting the ansible managed comment using the get_ansible_managed.j2
template and pass the comment to network_connections which is added
to the ifcfg file.

In case network_provider is nm, the comment is not added to the
ifcfg file as the file is not managed by Ansible.

Note: the required parameter name to pass the ansible managed comment
to the network_connection module is "__header".

Do not use get_ansible_managed.j2 in the test scripts, but use a
hardcoded ansible managed comment to simplify the tests.

tests/tasks/get_profile_stat.yml: replace the '=' style with the YAML
notation in set_fact.

Signed-off-by: Noriko Hosoi <nhosoi@redhat.com>
2022-02-25 06:10:42 +08:00
..
down_profile+delete_interface.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
down_profile.yml Integration tests: Explicitly select provider 2020-04-19 21:08:56 +02:00
files Add support for 802.1x wired connections (EAP-TLS only) 2020-03-25 10:49:10 +01:00
integration_pytest_python3.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
manual_test_ethtool_coalesce.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
remove_profile.yml Integration tests: Explicitly select provider 2020-04-19 21:08:56 +02:00
roles tests: Add missing roles symlink 2019-06-06 09:06:12 +02:00
run_tasks.yml Integration tests: Explicitly select provider 2020-04-19 21:08:56 +02:00
tasks tests: Test volatile state changes 2019-05-26 21:19:23 +02:00
tests_802_1x.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_802_1x_updated.yml Add ca_path option for 802.1x connections 2020-06-15 18:26:34 +02:00
tests_auto_gateway.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_bond.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_bond_deprecated.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_bond_options.yml Support more bond options 2022-02-11 23:40:34 +01:00
tests_bridge.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_checkpoint_cleanup.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_dummy.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_eth_dns_support.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_eth_pci_address_match.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_ethernet.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_ethtool_coalesce.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_ethtool_features.yml System Roles should consistently use ansible_managed in configuration files it manages 2022-02-25 06:10:42 +08:00
tests_ethtool_ring.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_ipv6.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_ipv6_disabled.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_ipv6_dns_search.yml Set DNS search setting only for enabled IP families 2021-12-21 09:18:38 +01:00
tests_provider.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_reapply.yml System Roles should consistently use ansible_managed in configuration files it manages 2022-02-25 06:10:42 +08:00
tests_route_table.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_states.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_switch_provider.yml tests: use down_profile+delete_interface instead of down_profile 2022-01-28 17:47:13 +01:00
tests_team.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_team_plugin_installation.yml Test installation of NetworkManager plugins 2021-03-05 11:57:16 +08:00
tests_vlan_mtu.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_wireless.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_wireless_plugin_installation.yml Test installation of NetworkManager plugins 2021-03-05 11:57:16 +08:00
tests_wireless_wpa3_owe.yml add support for ansible-core 2.11 ansible-lint, ansible-test 2021-10-11 12:03:00 -06:00
tests_wireless_wpa3_sae.yml wifi: Add Simultaneous Authentication of Equals(SAE) support 2021-08-09 09:59:22 +08:00