diff options
author | Rémi Flamary <remi.flamary@gmail.com> | 2016-10-28 17:04:32 +0200 |
---|---|---|
committer | Rémi Flamary <remi.flamary@gmail.com> | 2016-10-28 17:04:32 +0200 |
commit | 46e304dce30ab243c40174a4c6659cec358056d4 (patch) | |
tree | ffaaea95374c564e18f7183dc0939c19c95c555a /docs/source | |
parent | 71c152ab92ddb9405a2d975e2f84cc3f155d6975 (diff) |
RTD3
Diffstat (limited to 'docs/source')
-rw-r--r-- | docs/source/conf.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/docs/source/conf.py b/docs/source/conf.py index 1c1bb40..0031d77 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -14,9 +14,19 @@ import sys import os +from unittest.mock import MagicMock sys.path.insert(0, os.path.abspath("../..")) + +class Mock(MagicMock): + @classmethod + def __getattr__(cls, name): + return Mock() + +MOCK_MODULES = [ 'numpy', 'scipy'] +sys.modules.update((mod_name, Mock()) for mod_name in MOCK_MODULES) + # 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. |