ovito_update #40
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 will install Python dependencies, run tests and lint with a variety of Python versions | |
| # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | |
| name: Python Tests | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| repository_dispatch: | |
| types: [ovito_update] | |
| jobs: | |
| build: | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 15 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| python-version: ["3.10", "3.12", "3.13"] | |
| exclude: | |
| - os: macos-latest | |
| python-version: "3.10" | |
| - os: windows-latest | |
| python-version: "3.10" | |
| env: | |
| UV_SYSTEM_PYTHON: 1 | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Install apt dependencies | |
| if: matrix.os == 'ubuntu-latest' | |
| run: | | |
| sudo apt install -y libegl1 libopengl0 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| check-latest: true | |
| - name: Install uv (with cache) | |
| uses: astral-sh/setup-uv@v6 | |
| with: | |
| enable-cache: true | |
| - name: Install python dependencies | |
| run: | | |
| uv pip install --upgrade pip | |
| uv pip install pytest | |
| uv pip install --pre ovito | |
| uv pip install . | |
| - name: Test with pytest | |
| run: | | |
| pytest |