Dependencies and tox.ini clean-up
* Remove testscenarios, it's an ancient artefact * Replace the only usage of testtools with a simple check * Split out doc/requirements.txt * Clean tox.ini of unnecessary (and probably cargo-culted) stuff * Added Pygments for syntax highlighting check Change-Id: I9f6b03606973e1e8123165c46bef53c4ce8e2b92
This commit is contained in:
parent
81461b5b93
commit
7fd83d7d9b
3
doc/requirements.txt
Normal file
3
doc/requirements.txt
Normal file
@ -0,0 +1,3 @@
|
||||
sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD
|
||||
openstackdocstheme>=1.20.0 # Apache-2.0
|
||||
sphinxcontrib-apidoc>=0.2.0 # BSD
|
@ -15,8 +15,6 @@
|
||||
|
||||
from unittest import mock
|
||||
|
||||
from testtools.matchers import HasLength
|
||||
|
||||
from ironic_lib import disk_partitioner
|
||||
from ironic_lib import exception
|
||||
from ironic_lib.tests import base
|
||||
@ -55,7 +53,7 @@ class DiskPartitionerTestCase(base.IronicLibTestCase):
|
||||
'type': 'primary',
|
||||
'size': 2048})]
|
||||
partitions = [(n, p) for n, p in dp.get_partitions()]
|
||||
self.assertThat(partitions, HasLength(4))
|
||||
self.assertEqual(4, len(partitions))
|
||||
self.assertEqual(expected, partitions)
|
||||
|
||||
@mock.patch.object(disk_partitioner.DiskPartitioner, '_exec',
|
||||
|
@ -8,11 +8,5 @@ flake8-import-order>=0.17.1 # LGPLv3
|
||||
hacking>=3.0.0,<3.1.0 # Apache-2.0
|
||||
stestr>=1.0.0 # Apache-2.0
|
||||
oslotest>=3.2.0 # Apache-2.0
|
||||
testscenarios>=0.4 # Apache-2.0/BSD
|
||||
testtools>=2.2.0 # MIT
|
||||
|
||||
# Doc requirements
|
||||
doc8>=0.6.0 # Apache-2.0
|
||||
sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD
|
||||
openstackdocstheme>=1.20.0 # Apache-2.0
|
||||
sphinxcontrib-apidoc>=0.2.0 # BSD
|
||||
Pygments>=2.2.0 # BSD
|
||||
|
13
tox.ini
13
tox.ini
@ -13,7 +13,7 @@ setenv = VIRTUAL_ENV={envdir}
|
||||
LANGUAGE=en_US
|
||||
TESTS_DIR=./ironic_lib/tests/
|
||||
deps =
|
||||
-c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt}
|
||||
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
||||
-r{toxinidir}/test-requirements.txt
|
||||
-r{toxinidir}/requirements.txt
|
||||
commands = stestr run {posargs}
|
||||
@ -54,19 +54,16 @@ commands =
|
||||
commands = {posargs}
|
||||
|
||||
[testenv:docs]
|
||||
setenv = PYTHONHASHSEED=0
|
||||
sitepackages = False
|
||||
envdir = {toxworkdir}/venv
|
||||
deps =
|
||||
-c{env:UPPER_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master}
|
||||
-r{toxinidir}/doc/requirements.txt
|
||||
commands =
|
||||
sphinx-build -W -b html doc/source doc/build/html
|
||||
|
||||
|
||||
[testenv:pdf-docs]
|
||||
deps = {[testenv:docs]deps}
|
||||
whitelist_externals = make
|
||||
basepython = python3
|
||||
setenv = PYTHONHASHSEED=0
|
||||
sitepackages = False
|
||||
envdir = {toxworkdir}/venv
|
||||
commands = sphinx-build -b latex doc/source doc/build/pdf
|
||||
make -C doc/build/pdf
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user