From dc1f268c73ad811091d1ae33e47b5319415628d2 Mon Sep 17 00:00:00 2001 From: "georg.brandl" Date: Fri, 21 Mar 2008 14:03:25 +0000 Subject: Actually use the doctest_path setting. --- sphinx/ext/doctest.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sphinx/ext/doctest.py b/sphinx/ext/doctest.py index 2083e3ba..b9435f38 100644 --- a/sphinx/ext/doctest.py +++ b/sphinx/ext/doctest.py @@ -180,6 +180,8 @@ Doctest summary self.setup_failures, s(self.setup_failures))) self.outfile.close() + sys.path[0:0] = self.config.doctest_path + def write_doc(self, docname, doctree): groups = {} add_to_all_groups = [] @@ -201,7 +203,7 @@ Doctest summary code = TestCode(node.astext(), type=node.get('testnodetype', 'doctest'), lineno=node.line, options=node.get('options')) - node_groups = node.get('groups', ['default']) + node_groups = node.get('groups', ['doctest_block']) if '*' in node_groups: add_to_all_groups.append(code) continue @@ -277,4 +279,3 @@ def setup(app): # this config value adds to sys.path app.add_config_value('doctest_path', [], False) app.add_config_value('doctest_test_doctest_blocks', True, False) - -- cgit v1.2.1