Browse Source

Add ansible-role-jenkins-plugins to OpenStack

Change-Id: Ib27d78a1e2d0e1cb0dfb8ee215fa1e639221bfb9
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
changes/50/278650/1
Paul Belanger 3 years ago
parent
commit
8a1be893c2
2 changed files with 26 additions and 16 deletions
  1. 4
    0
      .gitreview
  2. 22
    16
      tox.ini

+ 4
- 0
.gitreview View File

@@ -0,0 +1,4 @@
1
+[gerrit]
2
+host=review.openstack.org
3
+port=29418
4
+project=openstack/ansible-role-jenkins-plugins.git

+ 22
- 16
tox.ini View File

@@ -1,36 +1,42 @@
1 1
 [tox]
2 2
 minversion = 1.4.2
3
-envlist = ansible-lint,docs,pep8
3
+envlist = docs,linters
4 4
 skipsdist = True
5 5
 
6 6
 [testenv]
7 7
 deps = -r{toxinidir}/requirements.txt
8 8
        -r{toxinidir}/test-requirements.txt
9 9
 
10
-[testenv:ansible-lint]
10
+[testenv:docs]
11
+commands = python setup.py build_sphinx
12
+
13
+[testenv:functional]
14
+commands =
15
+  ansible-playbook -i tests/inventory tests/test.yaml
16
+passenv = HOME
17
+setenv =
18
+  ANSIBLE_CONFIG = {toxinidir}/tests/ansible.cfg
19
+  PYTHONUNBUFFERED = 1
20
+
21
+[testenv:linters]
11 22
 setenv =
12 23
   ANSIBLE_CONFIG = tests/ansible.cfg
13 24
 whitelist_externals = bash
14 25
 commands =
26
+  flake8
15 27
   bash -c "find . -type f -regex '.*.y[a]?ml' -print0 | xargs -t -n1 -0 \
16 28
     ansible-lint"
17 29
   bash -c "find tests -type f -regex '.*.y[a]?ml' -print | xargs -t -n1 \
18 30
     ansible-playbook --syntax-check -i tests/inventory \
19 31
     -e rolename=$(basename $(pwd)) > /dev/null"
20 32
 
21
-[testenv:ansible-functional]
22
-commands =
23
-  ansible-playbook -i tests/inventory tests/test.yaml
24
-passenv = HOME
25
-setenv =
26
-  ANSIBLE_CONFIG = {toxinidir}/tests/ansible.cfg
27
-  PYTHONUNBUFFERED = 1
28
-
29
-[testenv:docs]
30
-commands = python setup.py build_sphinx
31
-
32
-[testenv:pep8]
33
-commands = flake8
34
-
35 33
 [testenv:venv]
36 34
 commands = {posargs}
35
+
36
+[flake8]
37
+# E123, E125 skipped as they are invalid PEP-8.
38
+
39
+show-source = True
40
+ignore = E123,E125
41
+builtins = _
42
+exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build

Loading…
Cancel
Save