Updates for python3.8

With the move to the Victoria job template in
https://review.opendev.org/#/c/722681/, the py37 jobs no
longer get run, so the check and gate job entries can
be removed.

Added a keepalived py38 KillFilter line to match the py36
and py37 ones.

Also updated TESTING.rst to use py38 in all examples.

Change-Id: Ief793b54d53c3239cfb24278e88e4f4189bbc2c2
This commit is contained in:
Brian Haley 2020-04-28 14:03:21 -04:00
parent 4b02ed8225
commit 4fb505891e
5 changed files with 13 additions and 16 deletions

View File

@ -132,7 +132,7 @@ __ file-based-sqlite_
.. code-block:: shell
$ OS_TEST_DBAPI_ADMIN_CONNECTION=sqlite:///sqlite.db .tox/py37/bin/python -m \
$ OS_TEST_DBAPI_ADMIN_CONNECTION=sqlite:///sqlite.db .tox/py38/bin/python -m \
testtools.run neutron.tests.unit...
...
(Pdb) self.engine.url
@ -507,7 +507,7 @@ To restrict the pylint check to only the files altered by the latest patch chang
To run only the unit tests::
tox -e py37
tox -e py38
Many changes span across both the neutron and neutron-lib repos, and tox
will always build the test environment using the published module versions
@ -520,7 +520,7 @@ For example, to run against the 'master' branch of neutron-lib::
cd $SRC
git clone https://opendev.org/openstack/neutron-lib
cd $NEUTRON_DIR
env TOX_ENV_SRC_MODULES=$SRC/neutron-lib tox -r -e py37
env TOX_ENV_SRC_MODULES=$SRC/neutron-lib tox -r -e py38
To run against a change of your own, repeat the same steps, but use the
directory with your changes, not a fresh clone.
@ -533,7 +533,7 @@ desired gerrit refs for this example)::
cd neutron-lib
git fetch https://opendev.org/openstack/neutron-lib refs/changes/13/635313/6 && git checkout FETCH_HEAD
cd $NEUTRON_DIR
env TOX_ENV_SRC_MODULES=$SRC/neutron-lib tox -r -e py37
env TOX_ENV_SRC_MODULES=$SRC/neutron-lib tox -r -e py38
Note that the '-r' is needed to re-create the tox virtual envs, and will also
be needed to restore them to standard when not using this method.
@ -542,7 +542,7 @@ Any pip installable package can be overriden with this environment variable,
not just neutron-lib. To specify multiple packages to override, specify them
as a space separated list to TOX_ENV_SRC_MODULES. Example::
env TOX_ENV_SRC_MODULES="$SRC/neutron-lib $SRC/oslo.db" tox -r -e py37
env TOX_ENV_SRC_MODULES="$SRC/neutron-lib $SRC/oslo.db" tox -r -e py38
Functional Tests
~~~~~~~~~~~~~~~~
@ -664,13 +664,13 @@ the dot-separated path you want as an argument to it.
For example, the following would run only a single test or test case::
$ tox -e py37 neutron.tests.unit.test_manager
$ tox -e py37 neutron.tests.unit.test_manager.NeutronManagerTestCase
$ tox -e py37 neutron.tests.unit.test_manager.NeutronManagerTestCase.test_service_plugin_is_loaded
$ tox -e py38 neutron.tests.unit.test_manager
$ tox -e py38 neutron.tests.unit.test_manager.NeutronManagerTestCase
$ tox -e py38 neutron.tests.unit.test_manager.NeutronManagerTestCase.test_service_plugin_is_loaded
If you want to pass other arguments to stestr, you can do the following::
$ tox -e py37 -- neutron.tests.unit.test_manager --serial
$ tox -e py38 -- neutron.tests.unit.test_manager --serial
Coverage

View File

@ -229,8 +229,8 @@ Create and activate the virtualenv
From the root of the neutron (or sub-project) repo directory, run::
tox --notest -r -e py37
source .tox/py37/bin/activate
tox --notest -r -e py38
source .tox/py38/bin/activate
Now you can use the ``test-db-manage`` alias in place of ``neutron-db-manage``
in the script auto-generation instructions below.

View File

@ -69,6 +69,7 @@ kill_keepalived_monitor_py: KillFilter, root, python, -15, -9
kill_keepalived_monitor_py3: KillFilter, root, python3, -15, -9
kill_keepalived_monitor_py36: KillFilter, root, python3.6, -15, -9
kill_keepalived_monitor_py37: KillFilter, root, python3.7, -15, -9
kill_keepalived_monitor_py38: KillFilter, root, python3.8, -15, -9
# For e.g. RHEL8 neutron-keepalived-state-change is run by "system python"
# which is /usr/libexec/platform-python3.6 so this should be in filters also.
# Path /usr/libexec isn't in PATH by default so it has to be given here as

View File

@ -6,7 +6,7 @@
# Why, you ask? Because you made changes to neutron-lib, and you want
# run the unit tests together. E.g.:
#
# env TOX_ENV_SRC_MODULES="$HOME/src/neutron-lib" tox -e py37
# env TOX_ENV_SRC_MODULES="$HOME/src/neutron-lib" tox -e py38
toxinidir="$1"

View File

@ -79,8 +79,6 @@
voting: false
- openstack-tox-py36: # from openstack-python3-victoria-jobs template
timeout: 3600
- openstack-tox-py37: # from openstack-python3-victoria-jobs template
timeout: 3600
- openstack-tox-py38: # from openstack-python3-victoria-jobs template
timeout: 3600
- openstack-tox-lower-constraints: # from openstack-tox-lower-constraints template
@ -103,8 +101,6 @@
- neutron-ovn-tempest-ovs-release
- openstack-tox-py36: # from openstack-python3-victoria-jobs template
timeout: 3600
- openstack-tox-py37: # from openstack-python3-victoria-jobs template
timeout: 3600
- openstack-tox-lower-constraints: # from openstack-tox-lower-constraints template
timeout: 3600
#- neutron-ovn-rally-task