diff -r f8ac01a762c1 Doc/library/unittest.rst --- a/Doc/library/unittest.rst Mon Nov 25 11:35:46 2013 -0800 +++ b/Doc/library/unittest.rst Mon Nov 25 23:07:32 2013 +0200 @@ -241,7 +241,11 @@ discovery, all of the test files must be :ref:`modules ` or :ref:`packages ` importable from the top-level directory of the project (this means that their filenames must be valid -:ref:`identifiers `). +:ref:`identifiers `). + +Also, discovery works with namespace packages (:pep:`420`) as well. +If a package can't be imported as a normal package, then the namespace +fallback will be used. Test discovery is implemented in :meth:`TestLoader.discover`, but can also be used from the command line. The basic command-line usage is:: @@ -1660,6 +1664,9 @@ given test suite is the same even if the underlying file system's ordering is not dependent on file name like in ext3/4. + .. versionchanged:: 3.4 + Test discovery supports namespace packages (:pep:`420`). + The following attributes of a :class:`TestLoader` can be configured either by subclassing or assignment on an instance: