This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author amaury.forgeotdarc
Recipients amaury.forgeotdarc, michael.foord
Date 2016-04-13.22:13:06
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1460585586.67.0.646853664072.issue26750@psf.upfronthosting.co.za>
In-reply-to
Content
When patching a class, mock.create_autospec() correctly detects properties and __slot__ attributes, but not subclasses of property() or other kinds of data descriptors.

The attached patch detects all data descriptors and patch them the way they should be.
History
Date User Action Args
2016-04-13 22:13:06amaury.forgeotdarcsetrecipients: + amaury.forgeotdarc, michael.foord
2016-04-13 22:13:06amaury.forgeotdarcsetmessageid: <1460585586.67.0.646853664072.issue26750@psf.upfronthosting.co.za>
2016-04-13 22:13:06amaury.forgeotdarclinkissue26750 messages
2016-04-13 22:13:06amaury.forgeotdarccreate