summaryrefslogtreecommitdiff
path: root/tests/test_config.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2010-01-17 18:24:35 +0100
committerGeorg Brandl <georg@python.org>2010-01-17 18:24:35 +0100
commit5a9a454631ff9e68cf1827ba1a9582a993dca8db (patch)
treefc4e18113c037d1ba74e6996f613e90e42fb5d37 /tests/test_config.py
parent31c5290fb8ffa8ff66ec30f5c8ac32c0fd31fbdb (diff)
downloadsphinx-git-5a9a454631ff9e68cf1827ba1a9582a993dca8db.tar.gz
Added ``needs_sphinx`` config value and ``Sphinx.require_sphinx`` application API function.
Diffstat (limited to 'tests/test_config.py')
-rw-r--r--tests/test_config.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/test_config.py b/tests/test_config.py
index 5193bebe4..0d18bf7f0 100644
--- a/tests/test_config.py
+++ b/tests/test_config.py
@@ -12,8 +12,9 @@
from util import *
+import sphinx
from sphinx.config import Config
-from sphinx.errors import ExtensionError, ConfigError
+from sphinx.errors import ExtensionError, ConfigError, VersionRequirementError
@with_app(confoverrides={'master_doc': 'master', 'nonexisting_value': 'True',
@@ -94,3 +95,8 @@ def test_errors_warnings(dir):
warned[0] = True
cfg.check_unicode(warn)
assert warned[0]
+
+
+def test_needs_sphinx():
+ raises(VersionRequirementError, TestApp,
+ confoverrides={'needs_sphinx': '9.9'})