From 31f444e4bae3c50fb93b57c19025a66ba2859d3b Mon Sep 17 00:00:00 2001 From: Jakub Warmuz Date: Tue, 24 Feb 2015 16:49:59 +0000 Subject: [PATCH] Mock augeas and M2Crypto in docs (fixes #262). --- docs/conf.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/conf.py b/docs/conf.py index 24792d644..3e4690a0f 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -17,6 +17,13 @@ import os import re import sys +import mock + + +# http://docs.readthedocs.org/en/latest/faq.html#i-get-import-errors-on-libraries-that-depend-on-c-modules +sys.modules.update( + (mod_name, mock.MagicMock()) for mod_name in ['augeas', 'M2Crypto']) + here = os.path.abspath(os.path.dirname(__file__)) # read version number (and other metadata) from package init