diff --git a/.zuul.yaml b/.zuul.yaml index ddcb9f46..534d3ab5 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -15,6 +15,7 @@ - stx-fault-build - fault-rest-api-py27 - fault-rest-api-py36 + - fault-rest-api-py3k gate: jobs: - openstack-tox-linters @@ -22,6 +23,7 @@ - fault-tox-pylint - fault-rest-api-py27 - fault-rest-api-py36 + - fault-rest-api-py3k post: jobs: - stx-fault-upload-git-mirror @@ -82,6 +84,18 @@ tox_envlist: py36 tox_extra_args: -c fm-rest-api/fm/tox.ini +- job: + name: fault-rest-api-py3k + parent: tox + description: | + Run py3k test for fm-rest-api + nodeset: ubuntu-bionic + required-projects: + - starlingx/config + vars: + tox_envlist: py3k + tox_extra_args: -c fm-rest-api/fm/tox.ini + - job: name: fault-tox-pylint parent: tox diff --git a/fm-rest-api/fm/tox.ini b/fm-rest-api/fm/tox.ini index 9ca42d2e..9de25ae7 100644 --- a/fm-rest-api/fm/tox.ini +++ b/fm-rest-api/fm/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py27,py36 +envlist = py27,py36,py3k minversion = 2.3 skipsdist = True stxdir = {toxinidir}/../../../ @@ -33,6 +33,16 @@ commands = stestr run {posargs} stestr slowest +[testenv:py3k] +basepython = python3 +deps = {[testenv]deps} + -e{toxinidir}/../../../config/tsconfig/tsconfig + -e{toxinidir}/../../../config/sysinv/cgts-client/cgts-client + -r{toxinidir}/../../requirements.txt + -r{toxinidir}/../../test-requirements.txt + +commands = pylint {posargs} --py3k -d W1618 -d W1641 fm --rcfile=../../pylint.rc + [testenv:cover] deps = {[testenv]deps} coverage diff --git a/tox.ini b/tox.ini index 6355540b..c4c35873 100644 --- a/tox.ini +++ b/tox.ini @@ -157,6 +157,10 @@ basepython = python3 whitelist_externals = cat commands = cat /etc/fm/fm.conf +[testenv:py3k] +basepython = python3 +description = Dummy environment to allow py3k to be run in subdir tox + [testenv:bandit] basepython = python3 description = Bandit code scan for *.py files under config folder