mirror of
https://github.com/ansible-collections/community.routeros.git
synced 2025-08-18 16:48:45 +02:00
Set default value for interface list include/exclude (#394)
Without a default value a pre-existing value isn't removed unless the caller specifies the property.
This commit is contained in:
parent
db716c1368
commit
fb070e4ac6
3 changed files with 4 additions and 10 deletions
2
changelogs/fragments/394-iface-list-defaults.yml
Normal file
2
changelogs/fragments/394-iface-list-defaults.yml
Normal file
|
@ -0,0 +1,2 @@
|
|||
minor_changes:
|
||||
- api_info, api_modify - set default value for ``include`` and ``exclude`` properties in ``system note`` to an empty string (https://github.com/ansible-collections/community.routeros/pull/394).
|
|
@ -441,8 +441,8 @@ PATHS = {
|
|||
fully_understood=True,
|
||||
fields={
|
||||
'comment': KeyInfo(can_disable=True, remove_value=''),
|
||||
'exclude': KeyInfo(),
|
||||
'include': KeyInfo(),
|
||||
'exclude': KeyInfo(default=''),
|
||||
'include': KeyInfo(default=''),
|
||||
'name': KeyInfo(),
|
||||
},
|
||||
),
|
||||
|
|
|
@ -470,8 +470,6 @@ class TestRouterosApiInfoModule(ModuleTestCase):
|
|||
{
|
||||
'.id': '*2000010',
|
||||
'name': 'WAN',
|
||||
'include': '',
|
||||
'exclude': '',
|
||||
'comment': 'defconf',
|
||||
},
|
||||
])
|
||||
|
@ -523,24 +521,18 @@ class TestRouterosApiInfoModule(ModuleTestCase):
|
|||
{
|
||||
'.id': '*2000000',
|
||||
'name': 'all',
|
||||
'include': '',
|
||||
'exclude': '',
|
||||
'builtin': True,
|
||||
'comment': 'contains all interfaces',
|
||||
},
|
||||
{
|
||||
'.id': '*2000001',
|
||||
'name': 'none',
|
||||
'include': '',
|
||||
'exclude': '',
|
||||
'builtin': True,
|
||||
'comment': 'contains no interfaces',
|
||||
},
|
||||
{
|
||||
'.id': '*2000010',
|
||||
'name': 'WAN',
|
||||
'include': '',
|
||||
'exclude': '',
|
||||
'builtin': False,
|
||||
'comment': 'defconf',
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue