mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-03-26 23:17:33 +00:00
[PR #11635/3c21ac96 backport][stable-12] nmcli: fix setting_types() to properly handle routing_rules as a list type (#11668)
nmcli: fix setting_types() to properly handle routing_rules as a list type (#11635)
* Fix setting_types() to properly handle routing_rules as a list type
* Add changelog fragment for ipv6.routing-rules bugfix
* Update changelogs/fragments/11630-nmcli-ipv6-routing-rules.yml
* Add PR URL to changelog fragment
---------
(cherry picked from commit 3c21ac961b)
Co-authored-by: Ted W. <ted.l.wood@gmail.com>
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
parent
8e4581c0e6
commit
9d7097ef4d
3 changed files with 5 additions and 0 deletions
2
changelogs/fragments/11630-nmcli-ipv6-routing-rules.yml
Normal file
2
changelogs/fragments/11630-nmcli-ipv6-routing-rules.yml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
bugfixes:
|
||||
- nmcli - add missing ``ipv6.routing-rules`` to ``settings_type()`` list type, preventing ``routing_rules6`` list from being corrupted (https://github.com/ansible-collections/community.general/issues/11630, https://github.com/ansible-collections/community.general/pull/11635).
|
||||
|
|
@ -2372,6 +2372,7 @@ class Nmcli:
|
|||
"ipv6.dns-search",
|
||||
"ipv6.dns-options",
|
||||
"ipv6.routes",
|
||||
"ipv6.routing-rules",
|
||||
"802-11-wireless-security.group",
|
||||
"802-11-wireless-security.leap-password-flags",
|
||||
"802-11-wireless-security.pairwise",
|
||||
|
|
|
|||
|
|
@ -2260,6 +2260,8 @@ def test_generic_connection_modify_routing_rules6(mocked_generic_connection_crea
|
|||
args, kwargs = arg_list[0]
|
||||
|
||||
assert "ipv6.routing-rules" in args[0]
|
||||
idx = args[0].index("ipv6.routing-rules")
|
||||
assert args[0][idx + 1] == "priority 5 from fd00::/24 table 5000,priority 10 from fd01::/24 table 5001"
|
||||
|
||||
out, err = capfd.readouterr()
|
||||
results = json.loads(out)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue