diff --git a/.zuul.yaml b/.zuul.yaml index 8b1f78d3..a3315e68 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -13,6 +13,8 @@ - project: check: jobs: + - airship-deckhand-tox-py27-postgresql + - airship-deckhand-tox-py35-postgresql - airship-deckhand-linter - airship-deckhand-ubuntu: voting: false @@ -21,6 +23,8 @@ - airship-deckhand-integration-uwsgi-py35 gate: jobs: + - airship-deckhand-tox-py27-postgresql + - airship-deckhand-tox-py35-postgresql - airship-deckhand-linter # NOTE(portdirect): enable when voting enabled. # - airship-deckhand-ubuntu: @@ -32,6 +36,22 @@ - airship-deckhand-functional-uwsgi-py35 - airship-deckhand-integration-uwsgi-py35 +- job: + name: airship-deckhand-tox-py27-postgresql + parent: openstack-tox-py27 + pre-run: + - tools/gate/playbooks/install-postgresql.yaml + vars: + tox_envlist: py27-postgresql + +- job: + name: airship-deckhand-tox-py35-postgresql + parent: openstack-tox-py35 + pre-run: + - tools/gate/playbooks/install-postgresql.yaml + vars: + tox_envlist: py35-postgresql + - job: name: airship-deckhand-linter description: | @@ -90,6 +110,7 @@ Run tox-based functional tests for the Airship Deckhand project using a minimalistic deployment consisting of uwsgi for Deckhand API and pifpaf for ephemeral PostgreSQL DB, under cPython version 3.5. + timeout: 3600 run: tools/gate/playbooks/run-functional-tests-uwsgi.yaml nodeset: openstack-helm-single-node vars: @@ -112,5 +133,6 @@ Run tox-based integration tests for the Airship Deckhand project using a minimalistic deployment consisting of uwsgi for Deckhand API and pifpaf for ephemeral PostgreSQL DB, under cPython version 3.5. + timeout: 3600 run: tools/gate/playbooks/run-integration-tests-uwsgi.yaml nodeset: openstack-helm-single-node diff --git a/tools/gate/playbooks/install-postgresql.yaml b/tools/gate/playbooks/install-postgresql.yaml new file mode 100644 index 00000000..73d0763f --- /dev/null +++ b/tools/gate/playbooks/install-postgresql.yaml @@ -0,0 +1,18 @@ +# Copyright 2018 AT&T Intellectual Property. All other rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +- hosts: all + gather_facts: False + roles: + - install-postgresql diff --git a/tools/run_pifpaf.sh b/tools/run_pifpaf.sh index 1fc9d1cc..dbf01d96 100755 --- a/tools/run_pifpaf.sh +++ b/tools/run_pifpaf.sh @@ -4,7 +4,8 @@ # upon test failure. function cleanup { - pifpaf_stop + set +e + pifpaf_stop || deactivate } trap cleanup EXIT