X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=bindings%2Fpython%2Fdocs%2Fsource%2Fconf.py;fp=bindings%2Fpython%2Fdocs%2Fsource%2Fconf.py;h=8b43c5ca3f9f1d019c49bf2ac3146186e14c828a;hp=5b901c4ec4d82e18ed3a406a8dd7915e34668422;hb=510dc8c8377e4fef1e96c13c2ea3f25f4b51c889;hpb=3c752b855f900f5251df9997514b4d27d9f38e83 diff --git a/bindings/python/docs/source/conf.py b/bindings/python/docs/source/conf.py index 5b901c4e..8b43c5ca 100644 --- a/bindings/python/docs/source/conf.py +++ b/bindings/python/docs/source/conf.py @@ -13,22 +13,13 @@ import sys, os +from unittest.mock import Mock + # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. sys.path.insert(0,os.path.abspath('../..')) -class Mock(object): - def __init__(self, *args, **kwargs): - pass - - def __call__(self, *args, **kwargs): - return Mock() - - @classmethod - def __getattr__(self, name): - return Mock() if name not in ('__file__', '__path__') else '/dev/null' - MOCK_MODULES = [ 'ctypes', ]