From cbb402ee6c06b6f57f98d0ec2f118e47ce07ad64 Mon Sep 17 00:00:00 2001 From: Vladyslav Drok Date: Fri, 19 Aug 2016 19:33:21 +0300 Subject: [PATCH] Add docs target to tox.ini Also fixes tempest imports related errors and adds warnerrors=True for pbr in setup.cfg. Change-Id: Ib27b5de1f014ebae0b66e945ed5a7628913c3a41 --- doc/source/conf.py | 5 +++++ setup.cfg | 3 +++ tox.ini | 7 +++++++ 3 files changed, 15 insertions(+) diff --git a/doc/source/conf.py b/doc/source/conf.py index 988d7e8fe..cda54be4d 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -37,6 +37,11 @@ add_module_names = True # The name of the Pygments (syntax highlighting) style to use. pygments_style = 'sphinx' +# A list of glob-style patterns that should be excluded when looking for +# source files. They are matched against the source file names relative to the +# source directory, using slashes as directory separators on all platforms. +exclude_patterns = ['api/ironicclient.tests.functional.*'] + # -- Options for HTML output -------------------------------------------------- # The theme to use for HTML and HTML Help pages. Major themes that come with diff --git a/setup.cfg b/setup.cfg index be13c072e..0755ab8cf 100644 --- a/setup.cfg +++ b/setup.cfg @@ -59,6 +59,9 @@ openstack.baremetal.v1 = [pbr] autodoc_index_modules = True +autodoc_exclude_modules = + ironicclient.tests.functional.* +warnerrors = True [build_sphinx] all_files = 1 diff --git a/tox.ini b/tox.ini index 3bde7cbb3..cf4f58211 100644 --- a/tox.ini +++ b/tox.ini @@ -38,6 +38,13 @@ commands = {posargs} setenv = TESTS_DIR=./ironicclient/tests/functional LANGUAGE=en_US +[testenv:docs] +setenv = PYTHONHASHSEED=0 +sitepackages = False +envdir = {toxworkdir}/venv +commands = + python setup.py build_sphinx + [flake8] ignore = exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools