Commit Graph

450 Commits

Author SHA1 Message Date
tonybrad 2295a6c47d update constraints url
See http://lists.openstack.org/pipermail/openstack-discuss/2019-May/006478.html

Change-Id: I7be44967f84e0da54596f4b111d5ee6aa55f9ee7
2019-06-12 18:23:42 +00:00
Chris Dent 70a2879b2c Delete the placement code
This finalizes the removal of the placement code from nova.
This change primarily removes code and makes fixes to cmd,
test and migration tooling to adapt to the removal.

Placement tests and documention were already removed in
early patches.

A database migration that calls
consumer_obj.create_incomplete_consumers in nova-manage has been
removed.

A functional test which confirms the default incomplete
consumer user and project id has been changes so its its use of
conf.placement.incomplete_* (now removed) is replaced with a
constant. The placement server, running in the functional
test, provides its own config.

placement-related configuration is updated to only register those
opts which are relevant on the nova side. This mostly means
ksa-related opts. placement-database configuration is removed
from nova/conf/database.

tox.ini is updated to remove the group_regex required by the
placement gabbi tests. This should probably have gone when the
placement functional tests went, but was overlooked.

A release note is added which describes that this is cleanup,
the main action already happened, but points people to the
nova to placement upgrade instructions in case they haven't
done it yet.

Change-Id: I4181f39dea7eb10b84e6f5057938767b3e422aff
2019-04-28 20:06:15 +00:00
ZhongShengping 7ecaa3fcf8 Replace git.openstack.org URLs with opendev.org URLs
Thorough replacement of git.openstack.org URLs with their opendev.org
counterparts.

Change-Id: I3e0af55e0707f04428a422b973d016ad30c82a12
2019-04-24 13:59:57 +08:00
Zuul 14c898173b Merge "Bump to hacking 1.1.0" 2019-04-16 08:25:27 +00:00
Ghanshyam Mann 6321f01f0c Dropping the py35 testing
All the integration testing has been moved to
Bionic now[1] and py3.5 is not tested runtime for
Train or stable/stein[2].

As per below ML thread, we are good to drop the py35
testing now:
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/005097.html

[1] http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004647.html
[2]
https://governance.openstack.org/tc/reference/runtimes/stein.html
https://governance.openstack.org/tc/reference/runtimes/train.html

Change-Id: Ia1289f038b92c36dbdd79bcdf12d7cb95a3e5aa9
Signed-off-by: zhangyangyang <zhangyangyang@unionpay.com>
2019-04-15 03:07:18 +00:00
Stephen Finucane 3e65f778bd Bump to hacking 1.1.0
This brings in a couple of new checks which must be addressed, many of
which involve a rather large amount of changes, so these are ignored for
now. A series of follow-up changes will resolved these.

'pycodestyle' is added as a dependency rather than it being pulled in
transitively. This is necessary since we're using it in tests.

Change-Id: I35c654bd39f343417e0a1124263ff31dcd0b05c9
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2019-04-12 16:23:49 +01:00
Chris Dent e5269f2fbb Correct lower-constraints.txt and the related tox job
In the review of a similar change in placement [1], it was realized that
the nova lower-constraints tox job probably had the same problems.
Testing revealed this to be the case. This change fixes the job and
updates the related requirements problems accordingly.

The are two main factors at play here:

* The default install_command in tox.ini uses the upper_contraints.txt
  file. When there is more than one constraints.txt they are merged and
  the higher constraints win. Using upper and lower at the same time
  violates the point of lower (which is to indicate the bare minimum
  we are capable of using).

* When usedevelop is true in tox, the command that is run to install the
  current projects code is something like 'python setup.py develop',
  which installs a project's requirements _after_ the install_command has
  run, clobbering the constrained installs. When using pbr,
  'python setup.py install' (used when usedevelop is False) does not do
  this.

Fixing those then makes it possible to use the test to fix the
lower-constraints.txt and *requirements.txt files, changes include:

* Defining 'usedevelop = False' in the 'lower-constraints' target and
  removing the otherwise superfluous 'skipsdist' global setting to
  ensure requirements aren't clobbered.

* Removing packages which show up in lower-constraints.txt but not in
  the created virtualenv. Note that the job only runs unit tests, so
  this may be incomplete. In the placement version of this both unit and
  functional are run. We may want to consider that here.

* Updating cryptography. This version is needed with more recent
  pyopenssl.

* Updated keystonemiddleware. This is needed for some tests which
  confirm passing configuration to the middleware.

* Update psycopg2 to a version that can talk with postgresql 10.

* Add PyJWT, used by zVMCloudConnector

* Update zVMCloudConnector to a version that works with Python 3.5 and
  beyond.

* Update olso.messaging to versions that work with the tests, under
  Python 3.

* Adding missing transitive packages.

* Adjusting alpha-ordering to map to how pip freeze does it.

* setuptools is removed from requirements.txt because the created
  virtualenv doesn't contain it

NOTE: The lower-constraints.txt file makes no commitment to expressing
minimum requirements for anything other than the current basepython.
So the fact that a different set of lower-constraints would be present
if we were using python2 is not relevant. See discussion at [1].
However, since requirements.txt _is_ used for python2, the
requirements-check gate job requires that enum34 be present in
lower-constraints.txt because it is in requirements.txt.

NOTE: A test is removed because it cannot work in the
lower-constraints context: 'test_policy_generator_from_command_line'
forks a call to 'oslopolicy-policy-generator --namespace nova' which
fails because stevedore fails to pick up nova-based entry points when
in a different process. This is because of the change to usedevelop.
After discussion with the original author of the test removal was
considered an acceptable choice.

[1] http://eavesdrop.openstack.org/irclogs/%23openstack-dev/%23openstack-dev.2019-03-05.log.html#t2019-03-05T13:28:23

Closes-Bug: #1822575

Change-Id: Ic6466b0440a4fe012731a63715cf5d793b6ae4dd
2019-04-01 19:16:33 +00:00
Zuul b25cc78ecb Merge "Fix deps for api-samples tox env" 2019-02-15 02:18:17 +00:00
Matt Riedemann 6ae35e11b8 Fix deps for api-samples tox env
The api-samples tox target fails since it needs the
PlacementFixture which comes from the placement repo.
This fixes it by using the same deps trick as the other
functional test environments.

As a result, the shared environment is also removed.

Change-Id: I815b8b3cff5dcbb0fc4be5f1d85019111c2009e5
2019-02-14 10:51:15 -05:00
Eric Fried 0225a988b3 Use tox 3.1.1 fixes
By 3.1.1, tox had fixed:
- [1] which mishandled the basepython directive.
- ignoring PYTHONDONTWRITEBYTECODE [2]

Require this version and remove the workarounds.

See ML thread [3] for some details

[1] https://github.com/tox-dev/tox/issues/477
[2] https://github.com/tox-dev/tox/commit/336f4f6bd8b53223f940fc5cfc43b1bbd78d4699
[3] http://lists.openstack.org/pipermail/openstack-dev/2018-July/thread.html#132075

Change-Id: Iff442451c7a95caa7b9d22c76c341150175a34d1
2019-02-12 10:30:47 -06:00
Eric Fried 590a2b6bbf tox: Don't write byte code (maybe)
In tox versions after 3.0.0rc1 [1], setting the environment variable
PYTHONDONTWRITEBYTECODE will cause tox not to write .pyc files, which
means you don't have to delete them, which makes things faster.

In older tox versions, the env var is ignored.

If we bump the minimum tox version to something later than 3.0.0rc1, we
can remove the commands that find and remove .pyc files.

[1] https://github.com/tox-dev/tox/commit/336f4f6bd8b53223f940fc5cfc43b1bbd78d4699

Change-Id: I779a17afade78997ab084909a9e6a46b0f91f055
2019-02-12 10:24:50 -06:00
Sean Mooney a32ccce6de cleanup *.pyc files in docs tox envs
.pyc files are ignored by nova's .gitignore, as a result
if you change branches after the .pyc files are generated
for example from stable/ocata to master it does not remove
the .pyc files.

This can lead to the _validate_bytecode_header function that
is invoked as part of sphinx-build to fail as the .pyc
files no longer match the contents of the checked out files.

This change adds {[testenv]commands} to the docs envs
to clean up stale .pyc files before running sphinx-build

Change-Id: I536a260da639d32afbc998be220305f9489db375
2019-02-06 19:41:15 +00:00
Chris Dent 01af1343f6 Make functional-py37 job work like others
The functional-* jobs have specific dependencies (external
placement) which need to be present in the job. When the
functional-py37 was created it conflicted with that change
but since it is not yet run in the gate, we didn't notice.

Also, because the functional jobs use the tox-siblings
functionality in the gate, the tox name and tox env have to
be the same (that's just how tox-siblings works), so that
is fixed here too.

Change-Id: I51e60a3149d653753ec4fc9d62a8c670e6eaf96e
2019-01-14 17:22:35 +00:00
Zuul 2cf77492ff Merge "Add python 3.7 unit and functional tox jobs" 2018-12-17 16:36:04 +00:00
Chris Dent 2ea552e019 Add python 3.7 unit and functional tox jobs
Without these, if you try to run tox -epy37,functional-py37 you'll
get a successful tox run, but no actual tests are run, which is
rather misleading. Given the generaly availability of python 3.7
this is a bad thing.

Running the tests under python 3.7 identified a few minor tests
failures, also fixed here. Each is a result of a change in behavior in
python 3.7:

* printable unicode changes with a new Unicode 11-based unicodedata
  package
* intentionally raising StopIteration in a generator is now considered a
  RuntimeError, 'return' should be used instead
* an exception message is different beween python 3 and python 2, and the
  guard for it was mapping python 3.5 and 3.6 but not 3.7.

zuul configuration is adjusted to add an experimental job for python 3.7
unit. A functional test job is not added, because we don't have 3.6 yet,
and we probably want to get through that first.

Closes-Bug: #1807976
Closes-Bug: #1807970
Change-Id: I37779a12d3b36eb3dc7e2733d07fe0ed23ab3da6
2018-12-13 10:41:46 -05:00
Chris Dent 787bb33606 Use external placement in functional tests
Adjust the fixtures used by the functional tests so they
use placement database and web fixtures defined by placement
code. To avoid making redundant changes, the solely placement-
related unit and functional tests are removed, but the placement
code itself is not (yet).

openstack-placement is required by the functional tests. It is not
added to test-requirements as we do not want unit tests to depend
on placement in any way, and we enforce this by not having placement
in the test env.

The concept of tox-siblings is used to ensure that the
placement requirement will be satisfied correctly if there is a
depends-on. To make this happen, the functional jobs defined in
.zuul.yaml are updated to require openstack/placement.

tox.ini has to be updated to use a envdir that is the same
name as job. Otherwise the tox siblings role in ansible cannot work.

The handling of the placement fixtures is moved out of nova/test.py
into the functional tests that actually use it because we do not
want unit tests (which get the base test class out of test.py) to
have anything to do with placement. This requires adjusting some
test files to use absolute import.

Similarly, a test of the comparison function for the api samples tests
is moved into functional, because it depends on placement functionality,

TestUpgradeCheckResourceProviders in unit.cmd.test_status is moved into
a new test file: nova/tests/functional/test_nova_status.py. This is done
because it requires the PlacementFixture, which is only available to
functional tests. A MonkeyPatch is required in the test to make sure that
the right context managers are used at the right time in the command
itself (otherwise some tables do no exist). In the test itself, to avoid
speaking directly to the placement database, which would require
manipulating the RequestContext objects, resource providers are now
created over the API.

Co-Authored-By: Balazs Gibizer <balazs.gibizer@ericsson.com>
Change-Id: Idaed39629095f86d24a54334c699a26c218c6593
2018-12-12 18:46:49 +00:00
Takashi NATSUME 311110e81b Remove Placement API reference
The placement project has published the API reference
in its own repository and the related jobs for the nova project
has been removed since Ia4680f24d78af1260f2f0106a458b78a079c1287.

So remove the files and definitions related to
the placement API reference in the nova repository.

Change-Id: Ia43b958a28e7e763e7ecb29e06f8d21d2b9a850f
2018-11-28 03:38:41 +00:00
Stephen Finucane f49b81fa2b tox: Stop build *all* docs in 'docs'
The 'docs' target currently builds the documentation trees in 'api-ref',
'api-guide' and 'placement-api-ref', in addition to 'doc'. This
massively increases the amount of time docs take to build both locally
and in the gate. It's not necessary for gate, since separate jobs take
care of the other documents for us [1]. As such, we should stop doing
it. For users that *do* care about this (for whatever reason) a new
'all-docs' target is included.

[1] https://github.com/openstack-infra/project-config/blob/master/zuul.d/projects.yaml#L5578-L5595

Change-Id: I58bd50e869fc00dde5dd388efb686a7196c8db80
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-10-26 18:00:53 +01:00
Takashi NATSUME a434b507fd Fix missing specifying doctrees directory
In tox.ini file, the doctrees directory is specified
as an argument of sphinx-build command in api-guide, api-ref,
placement-api-ref, releasenotes targets.
But it is missing in docs. So add it.

TrivialFix
Change-Id: I74ea98b1330c1c550dae53fafc79bd6e41727296
2018-09-20 20:48:35 +09:00
Chris Dent a8253805df Removing pip-missing-reqs from default tox jobs
Change I1b02384494ae9f440b72b98d9ae5f31d88dc8967 removed the
tox env entry for pip-missing-reqs but did not remove the job
from the envlist.

This means that if you run tox with no args it will run that job,
using the default venv setup with takes time but runs no tests.

Change-Id: I8355372da93b93cc1c7f7a1501af0fbd01eee615
2018-09-03 19:13:38 +01:00
Eric Fried ac3c90236c Remove blacklisted py3 xen tests
Xen UT failures seem to have cleared up, which may or may not have
anything to do with [1]. Remove the blacklist file and get these back
in the py3 jobs.

[1] https://review.openstack.org/#/c/591061/

Change-Id: Iacc1ae01f535caed64793d57b757ea07a8c46620
2018-08-14 16:34:19 +00:00
Chris Dent 05a73c36a0 Add explicit functional-py36 tox target
Without this, you can successfully run a 'functional-py36' environment,
but no actual tests are run. Python 3.6 is common in many environments
these days, and we want devs to test locally. This helps.

Change-Id: I2c04b7a8b6ee06638c6ce92dc51e200fa2b13539
2018-08-08 11:03:25 +01:00
Stephen Finucane a0614472df tox: Ensure reused envdirs share the same deps
In commit df669caf, we modified tox.ini to reuse a shared directory for
environments with the same dependencies. The 'venv' directory was
chosen as this seemed like a suitably generic target. However, the
'venv' target actually uses a non-default values for 'deps' as doc
requirements are included to allow things like reno using this target.
This means switching between the 'venv' target and any of the other
other targets using this directory will result in the virtualenv being
rebuilt each time.

Resolve this by using an explicit directory for these shared
environments. A single setting of 'deps' for one of the targets is
removed to make this clear.

Change-Id: I239606f5f354a5536b20b1d31ee81d80b4572106
2018-08-02 11:31:41 +01:00
Zuul 47ef500f44 Merge "Convert 'placement_api_docs' into a Sphinx extension" 2018-08-01 13:45:35 +00:00
Zuul 3c6f0eb49e Merge "tox: Reuse envdirs" 2018-07-30 15:02:21 +00:00
Stephen Finucane be5e6945a7 tox: Silence psycopg2 warnings
There's nothing we can do to fix this so simply silence it until we no
longer support that version.

Change-Id: Ic7a199a1374e6f36c092e5ca6faa435aa5bf4cbd
2018-07-24 14:28:07 +01:00
Sean Mooney 4ad83e7621 update tox venv env to install all requirements
- This change adds requirements.txt to the list
  of requirements files used when createing
  the tox venv environment.

Change-Id: Ib222b3cb68d2129c061400f51f50a19d186b9080
2018-07-17 19:44:05 +01:00
Stephen Finucane a34731dad1 Convert 'placement_api_docs' into a Sphinx extension
This ensures it will get run in the gate.

Change-Id: I923c39d3115b595b8de94e85d2977eb7782d98e2
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-07-02 11:21:47 +01:00
Stephen Finucane df669cafa5 tox: Reuse envdirs
This massively reduces the amount of time needed to install dependencies
and saves a lot of disk space to boot #winning

Note that it's not possible to use 'envdir = {[testenv:py27]envdir}' as
that syntax doesn't work with implicit attributes.

Change-Id: I229e1961a66db08be2d4f7235d2c3724e875f13b
2018-06-28 16:36:33 +01:00
Stephen Finucane 7601b3bb7f tox: Document and dedupe mostly everything
Take advantage of tox's expressiveness to avoid duplication wherever
possible and document the many targets we have.

Change-Id: I33675b7eedcffcebf1115dd48757874cb73f3e2f
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-06-28 15:24:17 +01:00
Stephen Finucane de4ab973d5 trivial: Remove 'tools/releasenotes_tox.sh'
This is not needed since reno 2.1.0 (commit f8fc8f97) [1].

[1] https://github.com/openstack/reno/commit/f8fc8f97ff20026582742e3e7838cdd0ed5cad68

Change-Id: I66ba0e0835970b965acce00ba69d143bd4471037
2018-06-28 15:06:46 +01:00
Doug Hellmann 3f98da0354 fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in [testenv].

We do not want to specify a minor version number, because we do not
want to have to update the file every time we upgrade python.

We must explicitly set basepython in envs that are usually "automatic" -
otherwise due to https://github.com/tox-dev/tox/issues/425 these will
use `basepython` instead of their automatic equivalents.

Change-Id: I1026110f0f1736127cf0af8ec2ef791a0f999e3a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-06-08 08:55:56 -05:00
Matt Riedemann 0a461979df Implement granular policy rules for placement
This adds a granular policy checking framework for
placement based on nova.policy but with a lot of
the legacy cruft removed, like the is_admin and
context_is_admin rules.

A new PlacementPolicyFixture is added along with
a new configuration option, [placement]/policy_file,
which is needed because the default policy file
that gets used in config is from [oslo_policy]/policy_file
which is being used as the nova policy file. As
far as I can tell, oslo.policy doesn't allow for
multiple policy files with different names unless
I'm misunderstanding how the policy_dirs option works.

With these changes, we can have something like:

  /etc/nova/policy.json - for nova policy rules
  /etc/nova/placement-policy.yaml - for placement rules

The docs are also updated to include the placement
policy sample along with a tox builder for the sample.

This starts by adding granular rules for CRUD operations
on the /resource_providers and /resource_providers/{uuid}
routes which use the same descriptions from the placement
API reference. Subsequent patches will add new granular
rules for the other routes.

Part of blueprint granular-placement-policy

Change-Id: I17573f5210314341c332fdcb1ce462a989c21940
2018-05-17 11:12:16 -04:00
Zuul dcdcb27360 Merge "add lower-constraints job" 2018-05-15 01:12:25 +00:00
Doug Hellmann e95af3f91c add lower-constraints job
Create a tox environment for running the unit tests against the lower
bounds of the dependencies.

Create a lower-constraints.txt to be used to enforce the lower bounds
in those tests.

Add openstack-tox-lower-constraints job to the zuul configuration.

See http://lists.openstack.org/pipermail/openstack-dev/2018-March/128352.html
for more details.

Change-Id: Ic28558ee6481d49a9b4e5dc2c4182504e330448f
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
Co-Authored-by: Eric Fried <efried@us.ibm.com>
Co-Authored-by: Jim Rollenhagen <jim@jimrollenhagen.com>
2018-05-14 16:47:07 +00:00
Stephen Finucane 35759d5e4b Remove stale pip-missing-reqs tox test
pip_missing_reqs tool is no longer maintained and has broken with
release 10 of pip

Refer to:
 http://lists.openstack.org/pipermail/openstack-dev/2018-April/130027.html

Change-Id: I1b02384494ae9f440b72b98d9ae5f31d88dc8967
2018-05-01 17:40:03 +01:00
melanie witt ef7e2a1988 Default to py3 for the pep8 tox env because it's stricter
We recently fixed a couple of pep8 failures under py3 [0] which got
through because we're not gating pep8 on py3. This changes the python
version for the pep8 tox env to python3 because the py3 checks are
stricter. This updates the fast8 tox env as well.

[0] https://review.openstack.org/#/c/557633

Change-Id: I540377606a8224ba569b8c145773e7d057575bd8
2018-04-04 15:24:00 +00:00
Stephen Finucane b862f6ff35 tox: Make everything work with Python 3
Nothing too fancy here except that we've to work around a really ugly
side-effect of blockdiag.

Change-Id: Ibd32d30aacae65702d0ccbdb8a02b1667ec4e8ee
2018-03-28 12:57:24 +01:00
Stephen Finucane a2821bdf6f tox: Remove unnecessary configuration
These were either unnecessary or overrode default configuration.

Change-Id: Ie17998dc564f06e9133c8412c24bc041b1e9a603
2018-03-26 15:12:28 +01:00
Stephen Finucane 9f5103f4e1 tox: Fix indentation
Makes life easier for future, actually important changes.

TrivialFix

Change-Id: Idda28f153d5054efc885ef2bde0989841df29cd3
2018-03-26 15:05:08 +01:00
Stephen Finucane c21ab6b134 Follow the new PTI for document build
The Project Testing Interface [1] asks that we list requirements in
'doc/requirements.txt' and build docs by calling 'sphinx-build' directly
instead of via the 'build_sphinx' setuptool/distutils wrapper. Start
doing this.

[1] https://governance.openstack.org/tc/reference/project-testing-interface.html

Change-Id: If9342c8ea757b1735f2488db751008984fb33baf
2018-03-16 14:39:36 +00:00
Zuul 912d6cbe0b Merge "Remove single quotes from posargs on stestr run commands" 2018-02-17 15:49:01 +00:00
Matthew Treinish 3b673dda6a Remove single quotes from posargs on stestr run commands
This commit removes the single quotes from all the stestr run commands
in the tox.ini. These were originally added as a workaround from the
ostestr days to ensure people could run a subset of tests with a regex
like:

  tox -epy27 regex

With the switch to stestr this is no longer needed because stestr treats
extra arguments as a filter regex. Quoting the posargs has a negative
effect because '--' parameters are treated as a string on input instead
of a parameter.

Fixing this also uncovered another issue in the stestr commands for the
functional jobs. The CLI arg for stestr versions <=1.1.0 is
--group_regex not --group-regex. This commit fixes this to make those
jobs pass without the quotes.

Change-Id: I512a517fa6890b29de24060376b4d7e061dc3add
2018-02-16 22:07:22 -05:00
Zuul 233285de49 Merge "add whereto for testing redirect rules" 2018-01-25 06:48:57 +00:00
Chris Dent ad34193059 Enable py36 unit tests in tox
With the current super-explicit version of tox.ini, it is not possible
to run tox -epy<any version> and have tests discovered and run. This
is because the default testenv does not run tests. Therefore, the
easiest way to add another version is to simply add another testenv,
as done in this change.

Python3.6 is the default Python3 on recent distributions so it needs
to be present if people are expected to be able to run python3 unit
tests before pushing their changes.

Change-Id: I728e482af3142bb101fc6bf52ec7926e29a42594
2018-01-16 10:14:46 +00:00
Matthew Treinish 9c56c78513 Finish stestr migration
Nova switched to using stestr for all it's in tree testing except for
the coverage job. This commit updates that job so it also uses stestr
and cleans up the last bits of testr setup left in tree. As part of
this change this moves all the one off per job configuration into the
tox job definitions instead of hiding it in either the .stestr.conf or
in a wrapper script.

Change-Id: I36e0e791d485b44641a1ed8770eca8e95aca19be
2017-11-24 16:51:12 -05:00
Doug Hellmann cec0faa711 add whereto for testing redirect rules
Use whereto to test that the redirect rules do what we expect. The
test coverage is a bit minimal for now, but should be useful as an
example of how it can be extended. The test files in the
openstack-manuals repo provide some other examples.

Depends-On: I36003d3525dcc9fef8e5f008ecabb2b2ac78088e
Change-Id: Ia14bfa6c89fd04844842d727d11ff8874ec7fc2a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-10-30 12:37:23 -04:00
melanie witt 53f244da12 Make setenv consistent for unit, func, and api-samples
Since ostestr switched to running stestr under the covers, we lost the
old magic setting of the environment variables via .testr.conf for
capturing stderr/stdout and the test timeout. This makes the unit,
functional, and api-samples envs consistent with the py27 env that was
already updated to set those variables.

This also updates the pretty_tox3.sh script to run stestr directly.

Change-Id: I27fa9b7e25c1a1dc921653eec84864423f898a85
2017-10-05 21:45:46 +00:00
Matthew Treinish 01b935cfe4 Add slowest command to tox.ini
This commit adds a printing of the 10 slowest tests during the run at
the end of the tox jobs. People have found this useful in the past and
ostestr used to do this by defualt. But, now that stestr is used to run
tests we need to make this call after a run to retain the output.

Change-Id: Ife81963e5ffb63e4ea09817e735eb768d7cf6209
2017-09-26 15:27:35 -04:00
Matthew Treinish 09fc560609 Add single quotes for posargs on jobs
People seem to hate the idea of using tox -epy27 -- foo to use a
test regex so add single quotes around posargs to make it so you can
just do tox -epy27 foo again.

Change-Id: I12c5d2dc78db3bc8954ff420492115ff53c42703
2017-09-15 11:15:06 -04:00