|
@@ -183,7 +183,7 @@ class TestUserResource(TestCase):
|
|
user = User("mapred", action = "create", groups = ['1','2','3'],
|
|
user = User("mapred", action = "create", groups = ['1','2','3'],
|
|
shell = "/bin/bash")
|
|
shell = "/bin/bash")
|
|
|
|
|
|
- popen_mock.assert_called_with(['/bin/bash', '--login', '--noprofile', '-c', "ambari-sudo.sh PATH=/bin -H -E usermod -G 1,2,3 -s /bin/bash mapred"], shell=False, preexec_fn=None, stderr=-2, stdout=5, bufsize=1, env={'PATH': '/bin'}, cwd=None)
|
|
|
|
|
|
+ popen_mock.assert_called_with(['/bin/bash', '--login', '--noprofile', '-c', 'ambari-sudo.sh PATH=/bin -H -E usermod -G 1,2,3,hadoop -s /bin/bash mapred'], shell=False, preexec_fn=None, stderr=-2, stdout=5, env={'PATH': '/bin'}, bufsize=1, cwd=None)
|
|
self.assertEqual(popen_mock.call_count, 1)
|
|
self.assertEqual(popen_mock.call_count, 1)
|
|
|
|
|
|
@patch.object(subprocess, "Popen")
|
|
@patch.object(subprocess, "Popen")
|