Skip to content

Refactor: documents endpoint #123

Refactor: documents endpoint

Refactor: documents endpoint #123

Workflow file for this run

name: Run Pytest
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
IMAGE_TAG: ${{ vars.GCP_REGION }}-docker.pkg.dev/${{ vars.GCP_PROJECT }}/${{ vars.GCP_CONTAINER_REPO }}/${{ vars.GCP_SERVICE }}:${{github.sha}}
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Set up app environment
run: |
cp .env.sample .env
- name: Build container image
uses: docker/build-push-action@v5
with:
cache-from: type=gha
cache-to: type=gha, mode=max
load: true
tags: ${{ env.IMAGE_TAG }}
- name: Run tests
env:
SERVICE_ACCOUNT_JSON: ${{ secrets.SERVICE_ACCOUNT_JSON }}
run: |
docker compose -f docker-compose.yaml -f docker-compose.test.yaml run app pytest -v