Test lchmod is called any any order

The test suite should not assume any particular order in which os.lchmod
is invoked.
This commit is contained in:
Lubomír Sedlář 2016-08-02 17:32:21 +02:00 committed by Mike McLean
parent a22054395b
commit df875e2619

View file

@ -434,7 +434,7 @@ class TasksTestCase(TestCase):
obj = TestTask(123, 'some_method', ['random_arg'], None, None, temp_path)
self.assertEquals(obj.chownTree(temp_path, 2, 0), None)
mock_lchown.assert_has_calls([call(temp_path, 2, 0), call(dummy_file2, 2, 0), call(dummy_file, 2, 0)])
mock_lchown.assert_has_calls([call(temp_path, 2, 0), call(dummy_file2, 2, 0), call(dummy_file, 2, 0)], any_order=True)
def test_BaseTaskHandler_localPath_file_exists(self):
""" Tests the localPath function to ensure that when a file exists, it returns that path without