Spaces:
Running on Zero
Running on Zero
| name: Simple Test Run | |
| on: | |
| push: | |
| branches: [ dev ] | |
| pull_request: | |
| branches: [ dev ] | |
| permissions: | |
| contents: read | |
| actions: read | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| env: | |
| SHOW_VLM_MODEL_OPTIONS: "False" | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Python 3.12 | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.12" | |
| - name: Install system dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| tesseract-ocr \ | |
| tesseract-ocr-eng \ | |
| poppler-utils \ | |
| libgl1-mesa-dri \ | |
| libglib2.0-0 \ | |
| libsm6 \ | |
| libxext6 \ | |
| libxrender-dev \ | |
| libgomp1 | |
| - name: Install Python dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements_lightweight.txt | |
| pip install pytest pytest-cov reportlab pillow | |
| - name: Download spaCy model | |
| run: | | |
| python -m spacy download en_core_web_lg | |
| - name: Setup test data | |
| run: | | |
| python .github/scripts/setup_test_data.py | |
| echo "Setup script completed. Checking results:" | |
| ls -la doc_redaction/example_data/ || echo "doc_redaction/example_data directory not found" | |
| - name: Verify test data files | |
| run: | | |
| echo "Checking if critical test files exist:" | |
| ls -la doc_redaction/example_data/ | |
| echo "Checking for specific PDF files:" | |
| ls -la doc_redaction/example_data/*.pdf || echo "No PDF files found" | |
| echo "Checking file sizes:" | |
| find doc_redaction/example_data -name "*.pdf" -exec ls -lh {} \; | |
| - name: Run CLI tests | |
| run: | | |
| cd test | |
| python cli_epilog_suite.py | |
| - name: Run tests with pytest | |
| run: | | |
| pytest test/ -v --tb=short | |