Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tersmitten committed Nov 6, 2020
1 parent 0b2deca commit f2bac90
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 10 deletions.
3 changes: 2 additions & 1 deletion .ansible-lint
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
skip_list:
warn_list:
- '106'
- '204'
- '405'
32 changes: 23 additions & 9 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ python:

env:
- ANSIBLE_VERSION=latest
- ANSIBLE_VERSION=2.10.2
- ANSIBLE_VERSION=2.10.1
- ANSIBLE_VERSION=2.10.0
- ANSIBLE_VERSION=2.9.14
Expand Down Expand Up @@ -45,6 +44,18 @@ env:
- ANSIBLE_VERSION=2.8.1
- ANSIBLE_VERSION=2.8.0

jobs:
include:
- python: "3.8"
env: ANSIBLE_VERSION=latest ANSIBLE_LINT_VERSION=latest
exclude:
- python: "2.7"
env: ANSIBLE_VERSION=latest
- python: "2.7"
env: ANSIBLE_VERSION=2.10.2
- python: "2.7"
env: ANSIBLE_VERSION=2.10.1

branches:
only:
- master
Expand All @@ -58,7 +69,14 @@ before_install:
install:
# Install Ansible.
- if [ "$ANSIBLE_VERSION" = "latest" ]; then pip install ansible; else pip install ansible==$ANSIBLE_VERSION; fi
- if [ "$ANSIBLE_VERSION" = "latest" ]; then pip install ansible-lint; fi
- >
if [ -n "$ANSIBLE_LINT_VERSION" ]; then
if [ "$ANSIBLE_LINT_VERSION" = "latest" ]; then
pip install ansible-lint;
else
pip install ansible-lint==$ANSIBLE_LINT_VERSION;
fi
fi
script:
# Check the role/playbook's syntax.
Expand All @@ -74,14 +92,10 @@ script:
&& (echo 'Idempotence test: pass' && exit 0)
|| (echo 'Idempotence test: fail' && exit 1)
# Test front-end
- >
wget http://localhost -O /dev/null -S --quiet 2>&1
| grep -q '503 Service Unavailable'
&& (echo 'Availability test: pass' && exit 0)
|| (echo 'Availability test: fail' && exit 1)
- if [ "$ANSIBLE_VERSION" = "latest" ]; then ansible-lint tests/test.yml; fi
if [ -n "$ANSIBLE_LINT_VERSION" ]; then
ansible-lint tests/test.yml;
fi
notifications:
email: false
Expand Down

0 comments on commit f2bac90

Please sign in to comment.