Skip to content

fix: shut down the containers after running ci #123

fix: shut down the containers after running ci

fix: shut down the containers after running ci #123

Workflow file for this run

name: Run Tests for Backend
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout page source
uses: actions/checkout@v3
- name: Build the Docker image and run tests
run: docker compose -f "backend/compose.test.yaml" up -d
- name: Print Logs for Container
run: |
errors=$(docker logs test_ci-1 2>&1 | grep "FAILED" -c)
if [ $errors -gt 0 ]; then
echo -e "unittest tests failed"
exit 1
fi