Skip to content

change tag to 1.3.0 #38

change tag to 1.3.0

change tag to 1.3.0 #38

Workflow file for this run

name: cicd_test
on:
# Run tests for non-draft pull request on master
pull_request:
branches:
- master
# Re-run tests when pull requests are merged to master
# (to prevent cases where merging fails)
push:
branches:
- master
jobs:
local_tests:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout branch
uses: actions/checkout@v5
# See https://github.com/marketplace/actions/setup-micromamba
- name: Install mamba environment
uses: mamba-org/setup-micromamba@v2.0.6
with:
environment-file: environment.yml
environment-name: altianalysis # activate the environment
cache-environment: true
cache-downloads: true
generate-run-shell: true
- name: Run unit tests
shell: micromamba-shell {0}
run: python -m pytest -m "not gpao" -s --log-cli-level DEBUG
gpao_tests:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
services:
database:
image: gpao/database:0.17.0
env:
POSTGRES_PASSWORD: postgres
ports:
- 5432:5432
api-gpao:
image: gpao/api-gpao:1.30.0
env:
PGHOST: database
PGPORT: 5432
PGUSER: postgres
PGPASSWORD: postgres
PGDATABASE: gpao
ports:
- 8080:8080
monitor-gpao:
image: gpao/monitor-gpao:1.46.0
ports:
- 8000:8000
steps:
- name: Log GPAO database
shell: bash
run: docker logs "${{ job.services.database.id }}"
- name: Log GPAO API
shell: bash
run: docker logs "${{ job.services.api-gpao.id }}"
- name: Docker ps
shell: bash
run: docker ps
- name: Test database connection
shell: bash
run: pg_isready -d gpao -h localhost -p 5432 -U postgres
- name: Test API connection
shell: bash
run: curl http://localhost:8080/api/projects
- name: Checkout branch
uses: actions/checkout@v5
# See https://github.com/marketplace/actions/setup-micromamba
- name: install
uses: mamba-org/setup-micromamba@v2.0.6
with:
environment-file: environment.yml
environment-name: altianalysis # activate the environment
cache-environment: true
cache-downloads: true
generate-run-shell: true
- name: Create local docker image
shell: bash
run: make docker-build
- name: Run GPAO tests
shell: micromamba-shell {0}
run: python -m pytest -m gpao -s --log-cli-level DEBUG