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
I think it's a great idea to have a check which enforces the usage of specs in mocks. So either spec, spec_set or autospec should be used when using mock.Mock or mocker.Mock. Same applies to MagicMock.
Rationale
This avoids unintended existence of magic attributes which can lead to non-failing tests even if a bug is introduced.
The text was updated successfully, but these errors were encountered:
Rule request
Description
I think it's a great idea to have a check which enforces the usage of specs in mocks. So either
spec
,spec_set
orautospec
should be used when usingmock.Mock
ormocker.Mock
. Same applies to MagicMock.Rationale
This avoids unintended existence of magic attributes which can lead to non-failing tests even if a bug is introduced.
The text was updated successfully, but these errors were encountered: