Merge pull request #127 from lbr-stack/fix/roboreg-126/ambiguous_memo… #138
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: Unit tests | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| env: | |
| PIP_NO_CACHE_DIR: "1" | |
| strategy: | |
| matrix: | |
| python-version: ["3.10", "3.11", "3.12"] | |
| fail-fast: false | |
| steps: | |
| # Free disk space | |
| - name: Free disk space | |
| run: | | |
| sudo rm -rf /usr/share/dotnet | |
| sudo rm -rf /opt/ghc | |
| sudo rm -rf /usr/local/lib/android | |
| sudo rm -rf /usr/local/.ghcup | |
| df -h | |
| # Check out the repository. | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| lfs: true | |
| # Set up the specified Python version. | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| # - name: cache | |
| # uses: actions/cache@v4 | |
| # with: | |
| # path: . | |
| # key: test_env_${{ matrix.python-version }} | |
| # ToDo: cuda dedicated needed? or enough via torch? | |
| # - uses: Jimver/cuda-toolkit@v0.2.21 | |
| # id: cuda-toolkit | |
| # with: | |
| # cuda: '12.1.0' | |
| # use-github-cache: false | |
| # use-local-cache: false | |
| # Upgrade pip and install build backend | |
| - name: Upgrade pip & install build tools | |
| run: | | |
| python -m pip install --upgrade pip setuptools wheel --no-cache-dir | |
| # Install roboreg (and its dependencies from pyproject.toml). | |
| - name: Install package and dependencies | |
| run: | | |
| pip install . --no-build-isolation --no-cache-dir | |
| # Run tests with pytest. | |
| - name: Run tests | |
| run: | | |
| pytest test |