You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mock out lchmod functions in _patch_for_wrapping_test?
TestRmtree._patch_for_wrapping_test already mocked out the regular
chmod functions in the os module and the Path class, to test what
happens when changing permissions cannot fix an error. But there
are also, on some systems and Python versions, lchmod versions of
these functions. This patches those as well.
I am not sure this should really be done. The problem is that
calling such functions is fairly likely to raise an exception if
it is not properly conditioned on a check for their actual
usability, and mocking them out could obscure such a bug.
0 commit comments