Merge pull request #771 from OptimalNothing90/fix/unbound-inv-stress-… #1873
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
| name: Python test | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: | |
| branches: [master] | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.os }} | |
| permissions: | |
| actions: read | |
| security-events: write | |
| contents: read | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| env: | |
| OS: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v5 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version-file: ".python-version" | |
| - name: Set up Python venv | |
| run: | | |
| uv venv | |
| shell: bash | |
| - name: Special dependencies for macos | |
| if: matrix.os == 'macos-latest' | |
| run: | | |
| source .venv/bin/activate | |
| brew install hdf5 | |
| brew install cbc | |
| uv pip install numpy==2.0.0 | |
| uv pip install tables==3.10.2 | |
| uv pip install pulp==3.0.2 | |
| uv run pulptest | |
| - name: Install EMHASS with test dependencies | |
| run: | | |
| uv sync --reinstall --extra test | |
| - name: Test with pytest | |
| run: | | |
| uv run pytest | |
| scan-pr: | |
| needs: | |
| - build | |
| uses: "google/osv-scanner-action/.github/workflows/osv-scanner-reusable.yml@v2.0.1" | |
| with: | |
| fail-on-vuln: false | |
| scan-args: |- | |
| --recursive | |
| ./ | |
| permissions: | |
| security-events: write | |
| contents: read | |
| actions: read |