mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 17:09:03 +00:00
single quotes
This commit is contained in:
parent
9f526217ad
commit
dbd0b386dc
@ -31,11 +31,11 @@ class UserTest(integration.ModuleCase,
|
||||
@destructiveTest
|
||||
@skipIf(os.geteuid() is not 0, 'you must be root to run this test')
|
||||
def test_user_not_present(self):
|
||||
"""
|
||||
'''
|
||||
This is a DESTRUCTIVE TEST it creates a new user on the minion.
|
||||
And then destroys that user.
|
||||
Assume that it will break any system you run it on.
|
||||
"""
|
||||
'''
|
||||
ret = self.run_state('user.present', name='salt_test')
|
||||
self.assertSaltTrueReturn(ret)
|
||||
ret = self.run_state('user.absent', name='salt_test')
|
||||
@ -44,9 +44,9 @@ class UserTest(integration.ModuleCase,
|
||||
@destructiveTest
|
||||
@skipIf(os.geteuid() is not 0, 'you must be root to run this test')
|
||||
def test_user_present_nondefault(self):
|
||||
"""
|
||||
'''
|
||||
This is a DESTRUCTIVE TEST it creates a new user on the on the minion.
|
||||
"""
|
||||
'''
|
||||
ret = self.run_state('user.present', name='salt_test',
|
||||
home='/var/lib/salt_test')
|
||||
self.assertSaltTrueReturn(ret)
|
||||
@ -57,13 +57,13 @@ class UserTest(integration.ModuleCase,
|
||||
@destructiveTest
|
||||
@skipIf(os.geteuid() is not 0, 'you must be root to run this test')
|
||||
def test_user_present_gid_from_name_default(self):
|
||||
"""
|
||||
'''
|
||||
This is a DESTRUCTIVE TEST. It creates a new user on the on the minion.
|
||||
This is an integration test. Not all systems will automatically create
|
||||
a group of the same name as the user, but I don't have access to any.
|
||||
If you run the test and it fails, please fix the code it's testing to
|
||||
work on your operating system.
|
||||
"""
|
||||
'''
|
||||
ret = self.run_state('user.present', name='salt_test',
|
||||
gid_from_name=True, home='/var/lib/salt_test')
|
||||
self.assertSaltTrueReturn(ret)
|
||||
@ -81,11 +81,11 @@ class UserTest(integration.ModuleCase,
|
||||
@destructiveTest
|
||||
@skipIf(os.geteuid() is not 0, 'you must be root to run this test')
|
||||
def test_user_present_gid_from_name(self):
|
||||
"""
|
||||
'''
|
||||
This is a DESTRUCTIVE TEST it creates a new user on the on the minion.
|
||||
This is a unit test, NOT an integration test. We create a group of the
|
||||
same name as the user beforehand, so it should all run smoothly.
|
||||
"""
|
||||
'''
|
||||
ret = self.run_state('group.present', name='salt_test')
|
||||
self.assertSaltTrueReturn(ret)
|
||||
ret = self.run_state('user.present', name='salt_test',
|
||||
@ -106,10 +106,10 @@ class UserTest(integration.ModuleCase,
|
||||
@destructiveTest
|
||||
@skipIf(os.geteuid() is not 0, 'you must be root to run this test')
|
||||
def test_user_present_groups_is_none(self):
|
||||
"""
|
||||
'''
|
||||
This is a DESTRUCTIVE TEST, it creates a new user and two groups on the
|
||||
minion.
|
||||
"""
|
||||
'''
|
||||
ret = self.run_state('group.present', name='salt_test')
|
||||
self.assertSaltTrueReturn(ret)
|
||||
ret = self.run_state('group.present', name='salt_test_2')
|
||||
@ -142,10 +142,10 @@ class UserTest(integration.ModuleCase,
|
||||
@destructiveTest
|
||||
@skipIf(os.geteuid() is not 0, 'you must be root to run this test')
|
||||
def test_user_present_groups_is_empty_list(self):
|
||||
"""
|
||||
'''
|
||||
This is a DESTRUCTIVE TEST, it creates a new user and two groups on the
|
||||
minion.
|
||||
"""
|
||||
'''
|
||||
ret = self.run_state('group.present', name='salt_test')
|
||||
self.assertSaltTrueReturn(ret)
|
||||
ret = self.run_state('group.present', name='salt_test_2')
|
||||
|
Loading…
Reference in New Issue
Block a user