Improve scikit-learn estimator compatibility #67
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: Tests | |
| on: | |
| push: | |
| branches: [ main, master ] | |
| pull_request: | |
| branches: [ main, master ] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| issues: read | |
| checks: write | |
| pull-requests: write | |
| actions: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| version: "0.11.19" | |
| python-version: "3.13" | |
| - name: Install dependencies | |
| run: uv sync --frozen --group dev | |
| - name: Run type checks | |
| run: uv run ty check | |
| - name: Run tests with coverage | |
| run: uv run pytest . -v -s --cov=tsgam_estimator --cov-report=xml --cov-report=html --cov-report=term --junitxml=junit.xml | |
| - name: Build package | |
| run: uv build | |
| - name: Check package contents | |
| run: uv run python scripts/check_package_contents.py | |
| - name: Check package metadata | |
| run: uv run --with twine twine check dist/* | |
| - name: Publish Test Results | |
| uses: EnricoMi/publish-unit-test-result-action@v2 | |
| with: | |
| files: junit.xml | |
| check_name: Test Results | |
| - name: Upload coverage reports to artifacts | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: coverage-reports | |
| path: | | |
| coverage.xml | |
| htmlcov/ | |
| - name: Coverage Comment | |
| uses: py-cov-action/python-coverage-comment-action@v3 | |
| with: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| MINIMUM_GREEN: 80 | |
| MINIMUM_ORANGE: 60 |