New submission from Jason R. Coombs <jar...@jaraco.com>:

In https://github.com/python/importlib_metadata/issues/302, I learned that the 
way unittest reports failures in tests is incentivizing the replacement of 
docstrings with comments in order not to make resolution of the relevant 
failing test more difficult to locate.

I presume I don't need to explain why docstrings are nice and preferable over 
comments.

Better would be for unittest to provide an option to ignore the docstrings or 
to emit the test path regardless of whether a docstring was present and to 
employ that option in CPython, allowing for docstrings in tests.

----------
components: Tests
messages: 408876
nosy: jaraco
priority: normal
severity: normal
status: open
title: Unittest output drives developers to avoid docstrings
versions: Python 3.11

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

Reply via email to