Brett Cannon <br...@python.org> added the comment:

A key question here is why are you trying to avoid the AttributeError case so 
much? If something has a bug and an attribute doesn't exist that should then 
that's a bug and the test needs to catch that. Now whether that's via an error 
from AttributeError being raise or an explicit failure case you still get 
notified, but there's a reason that we don't have attribute existence tests 
before every single attribute access throughout the test suite. ;) Basically 
unless the attribute is dynamic and thus you're explicitly testing the 
attribute got set then don't worry about it.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue37890>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to