Follow the new PTI for document build

For compliance with the Project Testing Interface as
described in [1]:
[1] https://governance.openstack.org/tc/reference/project-testing-interface.html
For more detials information, please refer to [2]:
[2] http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html

Change-Id: I648a78396a2e27f1d7197e89cddba73f8aa858aa
This commit is contained in:
junboli 2018-01-15 11:25:35 +08:00
parent 8716a37049
commit 173b11cb50
3 changed files with 21 additions and 8 deletions

6
doc/requirements.txt Normal file
View File

@ -0,0 +1,6 @@
# The order of packages is significant, because pip processes them in the order
# of appearance. Changing the order has an impact on the overall integration
# process, which may cause wedges in the gate later.
openstackdocstheme>=1.17.0 # Apache-2.0
reno>=2.5.0 # Apache-2.0
sphinx>=1.6.2 # BSD

View File

@ -2,10 +2,6 @@
# of appearance. Changing the order has an impact on the overall integration
# process, which may cause wedges in the gate later.
hacking!=0.13.0,<0.14,>=0.12.0 # Apache-2.0
# needed for doc build
sphinx>=1.6.2 # BSD
openstackdocstheme>=1.17.0 # Apache-2.0
reno>=2.5.0 # Apache-2.0
mock>=2.0.0 # BSD
coverage!=4.4,>=4.0 # Apache-2.0
oslotest>=1.10.0 # Apache-2.0

19
tox.ini
View File

@ -133,9 +133,14 @@ deps = {[tempestenv]deps}
commands = {posargs}
[testenv:docs]
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/requirements.txt
-r{toxinidir}/doc/requirements.txt
commands =
rm -rf doc/build
python setup.py build_sphinx {posargs}
rm -rf doc/build
sphinx-build -b html doc/source doc/build/html
whitelist_externals = rm
[testenv:pep8]
commands =
@ -161,9 +166,15 @@ enable-extensions = H106,H203,H904
import-order-style = pep8
[testenv:releasenotes]
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt}
-r{toxinidir}/requirements.txt
-r{toxinidir}/doc/requirements.txt
commands =
rm -rf releasenotes/build
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
rm -rf releasenotes/build
sphinx-build -a -E -W -d releasenotes/build/doctrees \
-b html releasenotes/source releasenotes/build/html
whitelist_externals = rm
[testenv:pip-check-reqs]
# Do not install test-requirements as that will pollute the virtualenv for