Add zuul to test-requirements for linting

The linters env is picking up zuul-jobs content too, so we need to add
zuul to get the zuul_ modules ... otherwise ansible-lint has a sad.

Add zuul to test-requirements like is done in zuul-jobs. Then point the
library path to zuul/ansible/library in the site-packages dir from tox
so that we pick up the right files.

Change-Id: I7a4f0159290d67354e0a73365091a0d1718762fd
This commit is contained in:
Monty Taylor 2018-10-18 08:34:33 -05:00
parent e5a2690247
commit d07d6d65ef
No known key found for this signature in database
GPG Key ID: 7BAE94BC7141A594
4 changed files with 13 additions and 0 deletions

View File

@ -5,3 +5,12 @@ libffi-devel [test platform:rpm]
libffi-dev [test platform:dpkg]
libssl-dev [platform:dpkg]
openssl-devel [platform:rpm]
python3-dev [compile test platform:dpkg platform:apk]
python3-devel [compile test platform:rpm]
libre2-dev [compile test platform:dpkg]
libre2-4 [platform:ubuntu-bionic]
libre2-3 [platform:debian-stretch]
libre2-1v5 [platform:ubuntu-xenial]
re2-devel [compile test platform:rpm]
re2-dev [platform:apk]
re2 [platform:rpm platform:apk]

View File

@ -4,6 +4,7 @@
hacking>=0.12.0,<0.13 # Apache-2.0
zuul
ansible<2.4.0
ansible-lint
bashate>=0.2

View File

@ -26,6 +26,8 @@ passenv =
# to export ANSIBLE_ROLES_PATH pointing to the currect repos.
# see openstack-zuul-jobs-linters job for more information.
ANSIBLE_ROLES_PATH
setenv =
ANSIBLE_LIBRARY= {envsitepackagesdir}/zuul/ansible/library
commands =
flake8 {posargs}
# Ansible lint

View File

@ -1190,6 +1190,7 @@
- openstack-infra/project-config
- openstack-infra/system-config
- openstack-infra/zuul-jobs
- openstack-infra/zuul
vars:
tox_envlist: linters
tox_environment: