Migrate test script from shell to python

- test.py needs to be called with 2 arguments : test_name and timeout
  - it will cd to test_name dir and use the test_name.yml from there
  - it will sleep for an amount of time equals to timeout in minutes
- it will perform health checks for containers. If healtcheck isn't enabled will check for running state
- it will run hooks inside the test_name dir ( .py and .sh) if there are any
- printing logs in any case
This commit is contained in:
Ionut Filip
2018-10-25 15:27:09 +03:00
parent 238d4e7f20
commit 3b1fdc6166
9 changed files with 109 additions and 2 deletions

View File

@@ -6,12 +6,17 @@ addons:
- docker-ce
env:
- VERSION=$TRAVIS_BRANCH
language: python
python:
- "3.6"
install:
- pip install -r tests/requirements.txt
script:
# Default to mailu for DOCKER_ORG
- if [ -z "$DOCKER_ORG" ]; then export DOCKER_ORG="mailu"; fi
- docker-compose -f tests/build.yml build
- tests/compose/test-script.sh
- python tests/compose/test.py
deploy:
provider: script