Reduce need for openstack specific requirements

- openstackdocstheme is only needed for docs builds. Move this and some
  missing doc-related requirements into the current convention of
  doc/requirements.txt so they are not installed when just using the
  library.
- oslotest is not used directly. It only helped pick up self.useFixture
  from testtools. Since nothing else is needed, just use testtools
  directly.

Change-Id: Ibfda6fbe91deaa846b62732c38eef93c393c926f
This commit is contained in:
Thomas Bechtold 2018-03-29 14:28:17 +02:00 committed by Sean McGinnis
parent 623f5bbe77
commit 383d3eebe1
No known key found for this signature in database
GPG Key ID: CE7EE4BFAF8D70C8
4 changed files with 14 additions and 7 deletions

7
doc/requirements.txt Normal file
View File

@ -0,0 +1,7 @@
# 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>=2.2.4 # Apache-2.0
reno>=3.1.0 # Apache-2.0
sphinx>=2.0.0,!=2.1.0 # BSD

View File

@ -15,9 +15,9 @@
# License for the specific language governing permissions and limitations
# under the License.
from oslotest import base
import testtools
class TestCase(base.BaseTestCase):
class TestCase(testtools.TestCase):
"""Test case base class for all unit tests."""

View File

@ -4,13 +4,8 @@
hacking>=3.0,<3.1.0 # Apache-2.0
coverage>=4.0,!=4.4 # Apache-2.0
openstackdocstheme>=2.2.1 # Apache-2.0
oslotest>=1.10.0 # Apache-2.0
ddt>=1.0.1 # MIT
python-subunit>=0.0.18 # Apache-2.0/BSD
sphinx>=2.0.0,!=2.1.0 # BSD
testrepository>=0.0.18 # Apache-2.0/BSD
testtools>=1.4.0 # MIT
# releasenotes
reno>=3.1.0 # Apache-2.0

View File

@ -16,6 +16,7 @@ setenv =
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/test-requirements.txt
commands = python setup.py test --slowest --testr-args='{posargs}'
[testenv:pep8]
@ -28,10 +29,14 @@ commands = {posargs}
commands = python setup.py test --coverage --testr-args='{posargs}'
[testenv:docs]
deps =
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
-r{toxinidir}/doc/requirements.txt
commands =
sphinx-build -W --keep-going -b html -d doc/build/doctrees doc/source doc/build/html
[testenv:releasenotes]
deps = {[testenv:docs]deps}
commands =
sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html