toastを追加 #26
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: Run Unit Tests on Pull Request | |
on: | |
pull_request: | |
branches: | |
- main | |
permissions: | |
contents: read | |
pull-requests: write | |
jobs: | |
pytest_coverage: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build and Start Services | |
run: | | |
docker-compose build | |
docker-compose up -d | |
sleep 20 | |
- name: Run Tests | |
run: | | |
docker container exec back poetry install --no-root | |
docker container exec back poetry run python -m migrate_db | |
docker container exec back poetry run pytest test/unit_test --asyncio-mode=auto --cov --cov-branch --cov-report=term-missing --junitxml=pytest.xml test | tee pytest-coverage.txt | |
- name: Pytest coverage comment | |
uses: MishaKav/pytest-coverage-comment@main | |
with: | |
pytest-coverage-path: ./pytest-coverage.txt | |
junitxml-path: ./pytest.xml |