add namespace to EventName #109
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: docker-compose-test | |
on: [ push, pull_request ] | |
jobs: | |
main: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-python@v2 | |
name: setup Python | |
with: | |
python-version: 3.8 | |
- name: Install dependencies | |
working-directory: docker_compose_test | |
run: | | |
python3 -m pip install --upgrade pip | |
pip3 install -r requirements.txt | |
- name: Docker Compose up -d --build | |
working-directory: docker_compose_test | |
run: | |
docker-compose up -d --build | |
- name: Wait for service to be ready | |
run: sleep 45 | |
- name: publish stations | |
working-directory: docker_compose_test | |
run: | | |
docker exec -t wis2box-api-test-wis2box-management wis2box metadata station publish-collection | |
- name: Check status code API | |
working-directory: docker_compose_test | |
run: | | |
status_code=$(curl -s -o /dev/null -w "%{http_code}" http://localhost:4343/oapi) | |
if [[ $status_code -ne 200 ]]; then | |
echo "Request failed with status code $status_code" | |
exit 1 | |
fi | |
- name: test synop publish | |
working-directory: docker_compose_test | |
run: | | |
python3 test_synop_publish.py | |
- name: test csv publish | |
working-directory: docker_compose_test | |
run: | | |
python3 test_csv_publish.py | |
- name: failed tests 🚩 | |
working-directory: docker_compose_test | |
if: ${{ failure() }} | |
run: | | |
docker-compose logs |