Skip to content

Do not merge. Just for research. #557

Do not merge. Just for research.

Do not merge. Just for research. #557

Workflow file for this run

name: CI
on:
pull_request:
push:
branches:
- 'v3'
concurrency:
group: ${{ github.event_name }}-${{ github.ref }}
jobs:
test:
name: Run tests & display coverage
runs-on: ubuntu-latest
permissions:
pull-requests: write
contents: write
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Install Poetry
run: |
pipx install poetry --python=python3.10
- name: Poetry caches
uses: actions/cache@v3
with:
path: |
~/.cache/
key: ${{ hashFiles('poetry.lock') }}
- name: Install deps
run: poetry install
- name: Run tests
run: poetry run pytest
env:
COVERAGE_COMMENT_E2E_GITHUB_TOKEN_USER_1: ${{ secrets.COVERAGE_COMMENT_E2E_GITHUB_TOKEN_USER_1 }}
COVERAGE_COMMENT_E2E_GITHUB_TOKEN_USER_2: ${{ secrets.COVERAGE_COMMENT_E2E_GITHUB_TOKEN_USER_2 }}
COVERAGE_COMMENT_E2E_ACTION_REF: ${{ github.sha }}
COVERAGE_COMMENT_E2E_REPO_SUFFIX: ${{ github.event.number }}
COVERAGE_COMMENT_E2E_PR_AUTHOR: ${{ github.event.pull_request.user.login }}
- name: Coverage comment
id: coverage_comment
uses: py-cov-action/python-coverage-comment-action@v3
with:
GITHUB_TOKEN: ${{ github.token }}
ANNOTATE_MISSING_LINES: true
- name: Store Pull Request comment to be posted
uses: actions/upload-artifact@v3
if: steps.coverage_comment.outputs.COMMENT_FILE_WRITTEN == 'true'
with:
name: python-coverage-comment-action
path: python-coverage-comment-action.txt