Skip to content

Run pytest tests

Run pytest tests #7

Workflow file for this run

name: Run pytest tests
on:
pull_request:
branches:
- main
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
- name: Run pytest
run: |
pytest my_code.py --junit-xml=.test_report.xml
- name: Upload summary
uses: test-summary/action@v2
with:
paths: ".test_report.xml"
if: always()