Remove unused imports for iosxr_acls (#67711)

Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
Paul Belanger 2020-02-24 17:47:35 -05:00 committed by GitHub
parent 8fbec3cdeb
commit 81ffc315a4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 13 deletions

View file

@ -22,14 +22,12 @@ from ansible.module_utils.network.iosxr.utils.utils \
prefix_to_address_wildcard,
is_ipv4_address
)
from ansible.module_utils.network.iosxr.argspec.acls.acls import AclsArgs
from ansible.module_utils.network.common.utils \
import (
to_list,
search_obj_in_list,
dict_diff,
remove_empties,
dict_merge,
)
from ansible.module_utils.six import iteritems
from ansible.module_utils.network.iosxr.facts.facts import Facts

View file

@ -13,7 +13,6 @@ based on the configuration.
from __future__ import absolute_import, division, print_function
__metaclass__ = type
import re
from copy import deepcopy
from collections import deque

View file

@ -10,7 +10,6 @@ from units.compat.mock import patch
from ansible.modules.network.iosxr import iosxr_acls
from units.modules.utils import set_module_args
from .iosxr_module import TestIosxrModule, load_fixture
import itertools
class TestIosxrAclsModule(TestIosxrModule):
@ -79,7 +78,7 @@ class TestIosxrAclsModule(TestIosxrModule):
'ipv4 access-list acl_1',
'10 permit ospf 192.168.1.0 0.0.0.255 any log'
]
result = self.execute_module(changed=True, commands=commands)
self.execute_module(changed=True, commands=commands)
def test_iosxr_acls_merged_idempotent(self):
set_module_args(
@ -97,7 +96,7 @@ class TestIosxrAclsModule(TestIosxrModule):
])
],
state="merged"))
result = self.execute_module(changed=False, commands=[])
self.execute_module(changed=False, commands=[])
def test_iosxr_acls_replaced(self):
set_module_args(
@ -120,7 +119,7 @@ class TestIosxrAclsModule(TestIosxrModule):
'ipv4 access-list acl_2', 'no 10', 'no 20',
'30 permit ospf 10.0.0.0 0.255.255.255 any log'
]
result = self.execute_module(changed=True, commands=commands)
self.execute_module(changed=True, commands=commands)
def test_iosxr_acls_replaced_idempotent(self):
set_module_args(
@ -143,7 +142,7 @@ class TestIosxrAclsModule(TestIosxrModule):
])
],
state="replaced"))
result = self.execute_module(changed=False, commands=[])
self.execute_module(changed=False, commands=[])
def test_iosxr_acls_overridden(self):
set_module_args(
@ -166,7 +165,7 @@ class TestIosxrAclsModule(TestIosxrModule):
'no ipv6 access-list acl6_1', 'ipv4 access-list acl_2', 'no 10',
'no 20', '40 permit ospf any any log'
]
result = self.execute_module(changed=True, commands=commands)
self.execute_module(changed=True, commands=commands)
def test_iosxr_acls_overridden_idempotent(self):
set_module_args(
@ -202,7 +201,7 @@ class TestIosxrAclsModule(TestIosxrModule):
])
],
state="overridden"))
result = self.execute_module(changed=False, commands=[])
self.execute_module(changed=False, commands=[])
def test_iosxr_acls_deletedaces(self):
set_module_args(
@ -212,19 +211,19 @@ class TestIosxrAclsModule(TestIosxrModule):
],
state="deleted"))
commands = ['ipv4 access-list acl_2', 'no 20']
result = self.execute_module(changed=True, commands=commands)
self.execute_module(changed=True, commands=commands)
def test_iosxr_acls_deletedacls(self):
set_module_args(
dict(config=[dict(afi="ipv6", acls=[dict(name="acl6_1")])],
state="deleted"))
commands = ['no ipv6 access-list acl6_1']
result = self.execute_module(changed=True, commands=commands)
self.execute_module(changed=True, commands=commands)
def test_iosxr_acls_deletedafis(self):
set_module_args(dict(config=[dict(afi="ipv4")], state="deleted"))
commands = ['no ipv4 access-list acl_2']
result = self.execute_module(changed=True, commands=commands)
self.execute_module(changed=True, commands=commands)
def test_eos_acls_rendered(self):
set_module_args(