예제 #1
0
 def test_list_groups(self):
     """
     Test if it return a list of groups the named user belongs to
     """
     with patch("salt.utils.user.get_group_list",
                MagicMock(return_value="Salt")):
         self.assertEqual(useradd.list_groups("name"), "Salt")
예제 #2
0
 def test_list_groups(self):
     '''
     Test if it return a list of groups the named user belongs to
     '''
     with patch('salt.utils.user.get_group_list',
                MagicMock(return_value='Salt')):
         self.assertEqual(useradd.list_groups('name'), 'Salt')
예제 #3
0
 def test_list_groups(self):
     '''
     Test if it return a list of groups the named user belongs to
     '''
     self.assertEqual(useradd.list_groups('name'), 'Salt')
예제 #4
0
파일: useradd_test.py 프로젝트: bryson/salt
 def test_list_groups(self):
     '''
     Test if it return a list of groups the named user belongs to
     '''
     self.assertEqual(useradd.list_groups('name'), 'Salt')