Merge pull request #761 from mrava87/ci-inteljax #1157
This file contains hidden or 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
| # This workflow uploads PyLops coverage analysis on Codacy | |
| # For more information see: https://github.com/codacy/codacy-coverage-reporter-action | |
| name: PyLops-coverage | |
| on: | |
| pull_request: | |
| push: | |
| branches: [dev] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check out source repository | |
| uses: actions/checkout@v6 | |
| with: | |
| fetch-depth: 0 | |
| - name: Install uv with Python | |
| uses: astral-sh/setup-uv@v6 | |
| with: | |
| python-version: "3.11" | |
| - name: Install dependencies and pylops | |
| run: uv sync --locked --extra advanced --extra stat --extra deep --all-groups | |
| - name: Coverage with pytest | |
| run: | | |
| uv run coverage run -m pytest | |
| uv run coverage xml | |
| uv run coverage html | |
| - name: Upload HTML coverage report | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage-html | |
| path: htmlcov/ | |
| - name: Run codacy-coverage-reporter | |
| if: github.event_name == 'push' | |
| uses: codacy/codacy-coverage-reporter-action@v1 | |
| with: | |
| project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} | |
| coverage-reports: coverage.xml |