bpo-30523: regrtest: Add --list-cases option by mlouielu · Pull Request #2238 · python/cpython

@mlouielu

@mlouielu

@mention-bot

@vstinner

* Add get_abs_module() function, use it in list_cases()
* list_cases() now logs skipped tests into stderr

vstinner

if isinstance(test, unittest.loader._FailedTest):
continue
elif isinstance(test, doctest.DocTestCase):
continue

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove this if: doctest falls into the the unittest.TestCase case, and... it just works! I'm able to pass to output to -m test --matchfile=tests and only these doctest tests are executed!

@@ -1,4 +1,5 @@
import datetime
import doctest

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this import (see above).

@mlouielu

This was referenced

Jun 16, 2017

vstinner added a commit that referenced this pull request

Jun 16, 2017