Skip to content

release v0.3.0

release v0.3.0 #1375

Workflow file for this run

# Builds the pyrit environment and runs all tests and pre-commit hooks
name: build_and_test
on:
push:
branches:
- "main"
pull_request:
branches:
- "main"
- "release/**"
workflow_dispatch:
concurrency:
# This ensures after each commit the old jobs are cancelled and the new ones
# run instead.
group: ${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
main-job:
strategy:
matrix:
os: [ubuntu-latest]
python: ["3.10", "3.11"]
package_name: ["pyrit"]
runs-on: ${{ matrix.os }}
# EnricoMi/publish-unit-test-result-action@v2 requires the following permissions
permissions:
contents: read
issues: read
checks: write
pull-requests: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
with:
python-version: ${{ inputs.python }}
- name: Install setuptools and pip
run: pip install --upgrade setuptools pip
- name: Install PyRIT with pip
run: pip install .[dev]
- name: Run unit tests with code coverage
run: make test-cov-xml
- name: Publish Pytest Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
files: '**/test-*.xml'
- name: Code Coverage Report
uses: irongut/CodeCoverageSummary@v1.3.0
with:
filename: coverage.xml
badge: true
fail_below_min: false
format: markdown
hide_branch_rate: false
hide_complexity: true
indicators: true
output: both
thresholds: '60 80'
- name: "Run pre-commit hooks"
run: pre-commit run --all-files