build #29
This file contains 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: build | |
on: [workflow_dispatch] | |
env: | |
HF_TOKEN: ${{ secrets.HF_TOKEN }} | |
jobs: | |
test: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macos-latest, macos-13, windows-latest] | |
python-version: ['3.8', '3.9', '3.10', '3.11'] | |
steps: | |
# Check out the repository code | |
- uses: actions/checkout@v4 | |
# Set up the specified Python version | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
# Install dependencies | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install -e ".[dev]" | |
# Run tests with pytest and generate coverage report | |
- name: Test with pytest | |
run: | | |
python -c "import os; print(os.environ.get('HF_TOKEN', '')[:3])" | |
pytest |