This commit is contained in:
tqchen 2015-07-26 12:29:18 -07:00
parent cef360d782
commit fef0ef26f1

View File

@ -15,6 +15,16 @@
import sys import sys
import os, subprocess import os, subprocess
import shlex import shlex
from mock import Mock as MagicMock
# mock out some of the modules to make docomentation easier
class Mock(MagicMock):
@classmethod
def __getattr__(cls, name):
return Mock()
MOCK_MODULES = ['pygtk', 'gtk', 'gobject', 'argparse', 'numpy', 'pandas']
sys.modules.update((mod_name, Mock()) for mod_name in MOCK_MODULES)
# If extensions (or modules to document with autodoc) are in another directory, # 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 # add these directories to sys.path here. If the directory is relative to the