mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Do not mock the ancestors of the specified modules in autodoc_mock_imports. Only mock the modules themselves and their descendants (as specified in the docs). Fix the test configs accordingly. Signed-off-by: Robin Jarry <robin@jarry.cc>
23 lines
619 B
Python
23 lines
619 B
Python
|
|
import missing_module
|
|
from missing_module import missing_name
|
|
import missing_package1.missing_module1
|
|
from missing_package2 import missing_module2
|
|
from missing_package3.missing_module3 import missing_name
|
|
import sphinx.missing_module4
|
|
from sphinx.missing_module4 import missing_name2
|
|
|
|
@missing_name
|
|
def decoratedFunction():
|
|
"""decoratedFunction docstring"""
|
|
return None
|
|
|
|
class TestAutodoc(object):
|
|
"""TestAutodoc docstring."""
|
|
@missing_name
|
|
def decoratedMethod(self):
|
|
"""TestAutodoc::decoratedMethod docstring"""
|
|
return None
|
|
|
|
sphinx.missing_module4.missing_function(len(missing_name2))
|