Commit Graph

37 Commits

Author SHA1 Message Date
Dmitriy Rabotyagov 07ae836651 Deprecate rsyslog_server role
Depends-On: https://review.opendev.org/c/openstack/project-config/+/863079
Change-Id: I2abe014ede0e3fa4ed07b22990c95beb2b847222
2022-10-31 16:59:05 +01:00
Jonathan Rosser d40741beea Cleanup setup.py config
Change-Id: I8580a9772d1e90620aa0ecdf393ea79659eacfff
2022-04-04 10:45:12 +01:00
zhoulinhui d522633042 Replace deprecated UPPER_CONSTRAINTS_FILE variable
Change-Id: I58413660900188e2af5dd51b3eb2dc2197614c61
2020-11-10 13:12:15 +08:00
melissaml 5c1ca98fe1 Cleanup py27 support
This repo is now testing only with Python
3, so let's make
a few cleanups:
- Remove python 2.7 stanza from setup.py
- Remove obsolete sections from setup.cfg
- Cleanup doc/source/conf.py to remove noww
 obsolete content.

Change-Id: I4a8fc095762151927cd9b0a63ba0f0af93d46b14
2020-05-20 21:01:10 +00:00
Ghanshyam Mann d7ecb11b99 [ussuri][goal] Updates for python 2.7 drop
OpenStack is dropping the py2.7 support in ussuri cycle.

Only update required is in tox to define common baspython as py3 os that
all tox env including [testenv:functional] will use py3 instead of py2.

Complete discussion & schedule can be found in
- http://lists.openstack.org/pipermail/openstack-discuss/2019-October/010142.html
- https://etherpad.openstack.org/p/drop-python2-support

Ussuri Communtiy-wide goal:
https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

Change-Id: I1afb7ef6ef2cced0be9d4c148adbcb873c5dfec1
2020-05-14 05:59:06 +00:00
jacky06 b02384309e tox: Keeping going with docs
1. Sphinx 1.8 introduced [1] the '--keep-going' argument which, as its name
suggests, keeps the build running when it encounters non-fatal errors.
This is exceptionally useful in avoiding a continuous edit-build loop
when undertaking large doc reworks where multiple errors may be
introduced.
2. Remove the unnecessary blank line for tox.ini

[1] https://github.com/sphinx-doc/sphinx/commit/e3483e9b045

Depends-On: Ie837d376bb1a1d93367369d25140dd8a9d5ac14e
Change-Id: Idf1ff2e8bfe9e012355c48e4e9590d43a336159c
2019-10-23 17:40:36 +00:00
melissaml abc9892eb7 Replace git.openstack.org URLs with opendev.org URLs
Change-Id: Ifad0fb43db0e1ba1885cf138bb029a89b289b934
2019-07-10 21:57:21 +08:00
huang.zhiping 289b30d46d fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

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 do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I55900a348452ebdcfc8dd40bb40a5a5aaeece994
Closes-Bug:  #1801657
2018-11-26 07:26:16 +00:00
Doug Hellmann 27f8dc029c fix tox python3 overrides
We want to default to running all tox environments under python 3, so
set the basepython value in each environment.

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 do not want to set the override once in testenv, because that
breaks the more specific versions used in default environments like
py35 and py36.

Change-Id: I4586d6a6a990840f48c13943b2ebfa368a858833
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2018-09-26 18:45:09 -04:00
Jesse Pretorius 8e09266e4d Use the TESTING_BRANCH env var for constraints
The TESTING_BRANCH environment variable is provided by the
run_tests.sh script and is derived from the .gitreview file.

This ensures that once the master branch becomes a stable
branch, the constraints from the stable branch in the
integrated repository will automatically get used once the
.gitreview file is updated.

To ensure that the required environment variables are present
we export them appropriately in run_tests.sh and modify the
tox configuration to pass them into the tox test.

Change-Id: If777b744f4a5c58d65f82b03a5b48a41c698d1d1
Needed-By: https://review.openstack.org/579371
2018-08-16 18:30:51 +01:00
Heba Naser 36dad1bb24 Use tests repo for common role test requirements
Using tox for requirements management requires in-repo
requirements files for all our repositories. Rather than
do that, we make use of the tests repo to capture our
common requirements and use this to install them.

This reduces our review requirement rate and simplifies
maintenance for us for the tox config. It also makes it
usable with 'Depends-On', which is marvellous!

The tox requirements definitions for docs/releasenotes
builds are left in-place as those are standard entries
across the community. If that changes at some point, we
can re-assess those entries too.

Depends-On: https://review.openstack.org/579208
Change-Id: I1e6f5dc891ba10bc12fdf3ba2eb5eb52db5c14e7
2018-07-02 12:17:51 -04:00
Jesse Pretorius 958937cfe9 Remove tests-repo-clone.sh
Now that run_tests.sh handles the tests repo clone, we can
remove the use of the older tests-repo-clone.sh script.

Change-Id: I5dd34c9eb8a7a18462a90c68c7345920291094c8
2018-03-28 10:18:09 +01:00
Jesse Pretorius 9693c50fd4 tox.ini: Expose USER environment variable to execution environment
In order to allow the use of the environment variable which informs
Ansible which user executed the playbook, we pass the USER env var
into the environment that tox builds.

Change-Id: I92a6564eb7dba6f55a27449e431853e8c4669457
Implements: blueprint python-build-install-simplification
Signed-off-by: Jesse Pretorius <jesse.pretorius@rackspace.co.uk>
2018-03-15 18:04:09 +00:00
ZhongShengping 8db9bb4411 Follow the new PTI for document build
For compliance with the Project Testing Interface as described in:
https://governance.openstack.org/tc/reference/project-testing-interface.html

For more detials information, please refer to:
http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html

Change-Id: If0e7e5af0973eea1a4f413dd1d5e5983101c1bb9
2018-03-09 12:01:28 +08:00
Jesse Pretorius 5461d331db Ensure that role tests pin pip/setuptools/wheel
Currently the role tests use whatever versions of pip,
setuptools and wheel are already installed on the host.

When a version of these tools changes it often causes
problems for our testing.

This will ensure that we use a known good set of pins
which is maintained in the general SHA bumping process.

Change-Id: Ie7f63df953f0808852284d1c94da40c22ab12928
2017-06-04 11:24:34 +01:00
Jesse Pretorius 5b9a0bdc0f Use zuul-cloner for tests repo in OpenStack-CI
When executing the tests repo clone in OpenStack-CI,
use zuul-cloner instead of git to enable cross-repo
testing. This ensures that if a dependent patch from
the tests repo is noted using 'Depends-On: <change-id>'
in the commit message, that patch will be included.

Depends-On: Idce7abebf32f24c356a27e099fbca954d917402b
Depends-On: I5da7802d61d2ab6b03908138e3a3ed2db22e3d29
Change-Id: I00c8e04c091177bc5c1692257204d6aac89c0bbc
2017-05-16 11:05:49 +00:00
gecong1973 57abc11af0 Use https instead of http for git.openstack.org
TrivialFix

Change-Id: I45ccac3946ec0088ccaa28ee3767e4fa7ac50857
2017-02-06 11:25:00 +08:00
gecong1973 0a4e4bc006 Delete deprecated Hacking in tox.ini
Some hacking have been removed,so we can delete them.
More details:
     https://github.com/openstack-dev/hacking/blob/master/setup.cfg

Change-Id: Idf7a2029a4003b11f91ce661fb9397d119833865
2016-12-05 09:35:02 +08:00
Jesse Pretorius 5d6165ccd8 Use upper constraints for all tox targets
With the implementation of https://review.openstack.org/388087 all
tox targets may now use upper constraints.

Change-Id: If1e04040053669afa1b830d97748af69cecd8021
2016-10-19 07:46:25 +01:00
Jesse Pretorius 0642d14320 Use centralised Ansible test scripts
This patch consumes the centralised Ansible test scripts
implemented in https://review.openstack.org/381853

Change-Id: I987a13705a4df53d7abf71dd2f5c0993694ae31f
2016-10-05 12:19:10 +01:00
Jesse Pretorius 54ffee2f2c Remove install_test_packages variable
With https://review.openstack.org/381479 merged, setting this
variable in tox.ini via an extra var is unnecessary.

Change-Id: I4d37e31fa548dda87c414a95f6cd15ef675c4b3c
2016-10-04 11:44:57 +01:00
Jesse Pretorius 73be7bee6b Use centralised test scripts
This patch consumes the test scripts implemented by
https://review.openstack.org/375061 to ensure that
the tests and test preparation is consistent and
more maintainable.

Change-Id: I38775ca18db04be8bcc40df8bb6194fcfa0e5adf
2016-09-28 12:08:30 +01:00
Kevin Carter e00580462e Update testing bits for consistency
Change-Id: I6263e91f7b83ace3a747569844a6218ec107c799
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-09-17 16:53:39 -04:00
Jesse Pretorius ba7b4b4a36 Compress test execution logs
The volume of logs we collect in CI jobs are extensive. This
patch ensures that the logs collected are compressed to reduce
the space taken in CI systems.

PYTHONUNBUFFERED is also set to ensure that the console log
from the CI jobs is recorded in the exact order of execution.

Change-Id: Ib9afec79a412938c66c09cf2283121c00c449e56
Related-Bug: #1620849
2016-09-09 10:56:36 +01:00
Kevin Carter 02eebf7884 Enable log collection after functional testing
This change enables log collection within the gate so that further analysis
on gate tasks can be performed post build. This is very useful when
debugging problems.

Change-Id: I9dbaf22bcc56e887cb3c4740968dc10a88734ab8
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2016-08-29 21:38:32 -05:00
Jesse Pretorius 37ba469f28 Make all linting tests use upper-constraints
As per [1] all linting tests can now use upper-constraints. This patch
removes all instances of the install_command override relating to lint
testing which were needed to negate the use of upper-constraints.

[1] http://lists.openstack.org/pipermail/openstack-dev/2016-August/101474.html

Change-Id: I02066b3659278d63a9a0aa89cf18254eeac2d418
2016-08-20 16:08:09 +01:00
Jean-Philippe Evrard 40cb670117 Include ansible commands for ansible linting
The plugin repo needs to be cloned for ansible-lint to
understand ansible plugins. The commands currently
reside in tox.ini under the ansible section and are not
currently included. This commit fixes that error.

Change-Id: I5bbd335eae52bfcf55fd915cb0389559a5654307
2016-08-11 18:12:08 +01:00
Jesse Pretorius c56338a664 Ensure that doc linting is included in the linters test
The 'docs' tox target executes the doc8 lint test which may result in
failures when testing documentation builds, but OpenStack-CI does not
execute that tox target.

In order to ensure that we catch all standard documentation syntax
errors and prevent them from merging, this patch includes the docs
target in the 'linters' chain of tests.

Fixes for any failures which result from executing this test are also
included in the patch.

Change-Id: Ie79b71af25287980e25ca6f552bcc5208a0e170d
2016-07-25 14:13:00 +01:00
Jesse Pretorius cd16029ac0 Use plugins repo version of the human_log callback plugin
With the implementation of https://review.openstack.org/321331 the
human_log callback plugin is now part of the plugins repo.

This patch removes the retrofitted version in tox in favor of using
the version from the plugins repo instead.

Change-Id: Ib6eae9af8fdf0a409da53fca1f86e87e28efeafe
2016-07-15 14:05:12 +01:00
Jesse Pretorius 118fb2d047 Implement doc8 checks for docs
In order to prepare for the move of detailed configuration
content from the install guide to the roles, doc8 checks
are being implemented in the roles to ensure that any new
content submitted is properly checked.

Change-Id: I10044b2e1232593840f65a927fe56e26c255f313
Partially-Implements: blueprint osa-install-guide-overhaul
2016-07-13 12:58:20 +01:00
Jesse Pretorius 6f7ffc4cc5 Update tox configuration
In order to prepare for implementing requirements management by the
OpenStack requirements management process, and to improve the
reliability and effectiveness of test execution, this patch implements
some changes to the tox configuration:

- The minimum tox version is increased in order to be able to use
  constraints for the python packages.
- The OpenStack upper-constraints are used when preparing the test
  venv for the linters checks.
- Any proxy environment variables set on the test host are passed
  into the venv to enable testing from behind a proxy.
- The environment variables used by Ansible tests are moved into
  a new venv called 'ansible' and this environment is inherited
  by all Ansible-related tests.
- The docs test will clean-up an existing build directory before
  executing the docs build.
- The releasenotes build cannot use upper-constraints at this point,
  so it doesn't.
- The Ansible role download will no longer ignore errors so that any
  problems discovered will result in a failed test.
- The human readable logging callback plugin is implemented for
  functional testing.
- The ansible test requirements are moved into tox.ini to ensure
  compliance for requirements.txt/test-requirements.txt for the
  global-requirements management contract.
- The ~/.ansible directory as a whole is not deleted. Instead only
  the plugins and roles folders are deleted to ensure that zuul's
  Ansible artifacts are left in-place.
- The ansible-lint version is updated to support execution against a
  folder, and the test now executes against the entire role to ensure
  that it captures all applicable files for lint testing.

This is a combined port of the following:
- https://review.openstack.org/323507
- https://review.openstack.org/338193
- https://review.openstack.org/332443
- https://review.openstack.org/338193
- https://review.openstack.org/339493

Change-Id: Ia805cb68284044d14638250c21020e54d41f439c
2016-07-08 13:37:54 +01:00
Jesse Pretorius 4904568e45 Add reno scaffolding for release notes management
Change-Id: Ifa6cb5d217d1529d35002a4a85e2001d43d76130
2016-04-09 19:22:44 +01:00
Jesse Pretorius b903273c7f Update tox config and add bashate E006, E040 exceptions
This patch updates the tox.ini the same bashate exceptions as are
currently in the OpenStack-Ansible playbook repo.

It also ensures that the linters and all lint targets work
appropriately and normalises the tox.ini configuration to use
uniform formatting.

The use of ansible.cfg is removed as there is no way of being
certain which paths can be used without reverting to an ugly
sed hack in the commands. This is why it is preferred to make
use of environment variables which make use of tox's default
substitutions instead. It's a more reliable way of achieving
the goal for the purpose of gating and testing.

The switch to using a git clone instead of ansible-galaxy to
download the plugins is due to the path spec not being able to
work in Ansible 2.x. [1]

[1] https://github.com/ansible/ansible/issues/13563

Change-Id: I2d5156028a9edc915f8d9a665d19e5a6e1728fb0
2016-02-12 12:01:56 +00:00
Jesse Pretorius b9ea5cb30e Revise all lint tests and add consolidated 'linters' tox environment
OpenStack-Infra has requested that lint tests be pipelined into the 'linters'
tox target in order to make more efficient use of nodepool resources.

This patch:

- Ensures that a complete set of lints tests is available in individual
  tox targets.
- Adds a 'linters' target which executes all the other lints tests.

Change-Id: Ic5ccc87e9adb08154532783f6215b015e31071ae
2016-02-03 13:19:24 +00:00
Paul Belanger 19dd1bdd91 Switch to testenv:functional
This brings our tox.ini files inline with other OpenStack projects.

Change-Id: I299c829fa95cc4259f23b811f41b415bc071a158
Depends-On: I376e51824c46f9b5eb4a4cff01aaa176632087dd
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-12-18 15:36:51 -05:00
Jesse Pretorius d45039d4f1 Merge bashate/pep8 lint jobs in common job
Instead of launching two separate build jobs in our CI infrastructure,
one for bashate and one for pep8, launch a single one. While the jobs
are short, the setup of the images takes a long time, so this is
friendlier to our CI infrastructure.

Use the pep8 environment as common lint target and merge the bashate job
into it.

This patch also renamed dev-requirements to test-requirements to bring it
into line with all other OpenStack projects.

Change-Id: I588af7c8cf5e15364e5be86a41c1153ba3a5cbba
2015-12-15 10:38:07 +00:00
Kevin Carter 2b4bf4547c
first commit
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2015-12-09 09:27:53 -06:00