test catalog prepration sepratly from unittests #8
Workflow file for this run
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: Test Catalog Validity and Freshness | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
run-catalog-prepration: | |
runs-on: ubuntu-latest | |
env: | |
OS: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.8' | |
cache: 'pip' # caching pip dependencies | |
- run: pip install -r requirements/base.rqr | |
- run: pip install -r requirements/tests.rqr | |
- run: pip install unittest-parallel | |
- run: pip install "huggingface_hub[cli]" | |
- run: git config --global credential.helper store | |
- run: huggingface-cli login --token ${{ secrets.UNITXT_READ_HUGGINGFACE_HUB_FOR_TESTS }} --add-to-git-credential | |
- name: Delete Catalog | |
run: rm -rf src/unitxt/catalog/* | |
- name: Run Preperation | |
env: | |
HUGGINGFACE_HUB_TOKEN: ${{ secrets.UNITXT_READ_HUGGINGFACE_HUB_FOR_TESTS }} | |
UNITXT_TEST_CARD_DISABLE: True | |
UNITXT_TEST_METRIC_DISABLE: True | |
run: python -m unittest discover -s tests/catalog -p "test_*.py" | |
- name: Check for Uncommitted Changes | |
run: | | |
git diff --exit-code |