Run functional tests on Python 3
The functional job roles are extended with an option to specify python version to run with and a new CI job is created. python-memcached is added to requirements.txt, since it is used in the default keystonemiddleware configuration. Change-Id: I0b77b150785a90b411cba4ffc4b89cc67646e2ac
This commit is contained in:
parent
ed1838b7af
commit
85b776bc86
13
.zuul.yaml
13
.zuul.yaml
@ -3,6 +3,8 @@
|
|||||||
jobs:
|
jobs:
|
||||||
- novajoin-functional:
|
- novajoin-functional:
|
||||||
voting: false
|
voting: false
|
||||||
|
- novajoin-functional-py3:
|
||||||
|
voting: false
|
||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: novajoin-functional
|
name: novajoin-functional
|
||||||
@ -39,3 +41,14 @@
|
|||||||
# Disable Cinder services
|
# Disable Cinder services
|
||||||
c-bak: false
|
c-bak: false
|
||||||
c-vol: false
|
c-vol: false
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: novajoin-functional-py3
|
||||||
|
description: |
|
||||||
|
Run functional tests under Python 3.
|
||||||
|
parent: novajoin-functional
|
||||||
|
nodeset: devstack-single-node-fedora-latest
|
||||||
|
vars:
|
||||||
|
tox_envlist: functional-py3
|
||||||
|
bindep_profile: test py3
|
||||||
|
python_version: 3
|
||||||
|
@ -3,3 +3,6 @@
|
|||||||
|
|
||||||
python-ipalib
|
python-ipalib
|
||||||
python-ipaclient
|
python-ipaclient
|
||||||
|
|
||||||
|
python3-ipalib [py3]
|
||||||
|
python3-ipaclient [py3]
|
||||||
|
@ -7,6 +7,7 @@ Paste>=2.0.2 # MIT
|
|||||||
Routes>=2.3.1 # MIT
|
Routes>=2.3.1 # MIT
|
||||||
six>=1.10.0 # MIT
|
six>=1.10.0 # MIT
|
||||||
python-keystoneclient>=3.8.0 # Apache-2.0
|
python-keystoneclient>=3.8.0 # Apache-2.0
|
||||||
|
python-memcached>=1.59 # PSF
|
||||||
keystoneauth1>=3.3.0 # Apache-2.0
|
keystoneauth1>=3.3.0 # Apache-2.0
|
||||||
oslo.concurrency>=3.25.0 # Apache-2.0
|
oslo.concurrency>=3.25.0 # Apache-2.0
|
||||||
oslo.config>=6.1.0 # Apache-2.0
|
oslo.config>=6.1.0 # Apache-2.0
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
name: urllib3
|
name: urllib3
|
||||||
state: absent
|
state: absent
|
||||||
become: true
|
become: true
|
||||||
|
when: python_version is not defined
|
||||||
|
|
||||||
- name: Install FreeIPA
|
- name: Install FreeIPA
|
||||||
package:
|
package:
|
||||||
@ -35,6 +36,7 @@
|
|||||||
check_mode: true
|
check_mode: true
|
||||||
ignore_errors: yes
|
ignore_errors: yes
|
||||||
register: mod_nss_check
|
register: mod_nss_check
|
||||||
|
become: true
|
||||||
|
|
||||||
- name: Remove mod_ssl config which conflicts with FreeIPA
|
- name: Remove mod_ssl config which conflicts with FreeIPA
|
||||||
file:
|
file:
|
||||||
|
@ -1,10 +1,16 @@
|
|||||||
- name: Build novajoin
|
- name: Build novajoin
|
||||||
command: python setup.py build
|
command: python{{ python_version|default('') }} setup.py build
|
||||||
args:
|
args:
|
||||||
chdir: '{{ zuul.project.src_dir }}'
|
chdir: '{{ zuul.project.src_dir }}'
|
||||||
|
|
||||||
|
- name: Install novajoin requirements
|
||||||
|
command: python{{ python_version|default('') }} -m pip install -r requirements.txt
|
||||||
|
args:
|
||||||
|
chdir: '{{ zuul.project.src_dir }}'
|
||||||
|
become: true
|
||||||
|
|
||||||
- name: Install novajoin
|
- name: Install novajoin
|
||||||
command: python setup.py install
|
command: python{{ python_version|default('') }} setup.py install
|
||||||
args:
|
args:
|
||||||
chdir: '{{ zuul.project.src_dir }}'
|
chdir: '{{ zuul.project.src_dir }}'
|
||||||
become: true
|
become: true
|
||||||
|
10
tox.ini
10
tox.ini
@ -76,3 +76,13 @@ setenv =
|
|||||||
commands =
|
commands =
|
||||||
/usr/bin/find . -type f -name "*.py[c|o]" -delete
|
/usr/bin/find . -type f -name "*.py[c|o]" -delete
|
||||||
stestr run --slowest {posargs}
|
stestr run --slowest {posargs}
|
||||||
|
|
||||||
|
[testenv:functional-py3]
|
||||||
|
basepython = python3
|
||||||
|
sitepackages = true
|
||||||
|
deps = -r{toxinidir}/test-requirements.txt
|
||||||
|
setenv =
|
||||||
|
OS_TEST_PATH={toxinidir}/novajoin/tests/functional
|
||||||
|
commands =
|
||||||
|
/usr/bin/find . -type f -name "*.py[c|o]" -delete
|
||||||
|
stestr run --slowest {posargs}
|
||||||
|
Loading…
Reference in New Issue
Block a user