mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-02-04 08:13:38 +00:00
users: tests: restore previous value of restricted access
Signed-off-by: Joseph Nuthalapati <njoseph@thoughtworks.com> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
dafd2f113e
commit
81f4d7ec42
@ -84,7 +84,9 @@ class TestActions(unittest.TestCase):
|
||||
'..', 'actions', 'users')
|
||||
self.users = set()
|
||||
self.groups = set()
|
||||
security.set_restricted_access(False)
|
||||
self.restricted_access = security.get_restricted_access_enabled()
|
||||
if self.restricted_access:
|
||||
security.set_restricted_access(False)
|
||||
|
||||
def tearDown(self):
|
||||
for user in self.users:
|
||||
@ -96,7 +98,7 @@ class TestActions(unittest.TestCase):
|
||||
for group in self.groups:
|
||||
self.delete_group(group)
|
||||
|
||||
security.set_restricted_access(True)
|
||||
security.set_restricted_access(self.restricted_access)
|
||||
|
||||
def call_action(self, arguments, **kwargs):
|
||||
"""Call the action script."""
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user