@mock.patch.object(os.path, 'exists', autospec=True)
@mock.patch.object(utils, '_check_dir_writable', autospec=True)
@mock.patch.object(utils, '_check_dir_free_space', autospec=True)
def test_check_dir_with_pass_in(self, mock_free_space, mock_dir_writable, mock_exists):
    mock_exists.return_value = True
    utils.check_dir(directory_to_check='/fake/path', required_space=5)
    mock_exists.assert_called_once_with('/fake/path')
    mock_dir_writable.assert_called_once_with('/fake/path')
    mock_free_space.assert_called_once_with('/fake/path', 5)
@mock.patch.object(os.path, 'exists', autospec=True)
@mock.patch.object(utils, '_check_dir_writable', autospec=True)
@mock.patch.object(utils, '_check_dir_free_space', autospec=True)
def test_check_dir_with_pass_in(self, mock_free_space, mock_dir_writable, mock_exists):
    mock_exists.return_value = True
    utils.check_dir(directory_to_check='/fake/path', required_space=5)
    mock_exists.assert_called_once_with('/fake/path')
    mock_dir_writable.assert_called_once_with('/fake/path')
    mock_free_space.assert_called_once_with('/fake/path', 5)