Test Run #24
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: Test Run | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| test_class: | |
| description: 'Test class or file to run (e.g., tests/test_example.py::TestClassName)' | |
| required: false | |
| default: '' | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| pip install allure-pytest | |
| pip install playwright | |
| playwright install | |
| - name: Install Allure CLI | |
| run: | | |
| wget -q https://github.com/allure-framework/allure2/releases/download/2.21.0/allure-2.21.0.zip -O allure.zip | |
| unzip allure.zip -d allure | |
| echo "$PWD/allure/allure-2.21.0/bin" >> $GITHUB_PATH | |
| chmod +x allure/allure-2.21.0/bin/allure | |
| - name: Run tests and generate Allure report | |
| run: bash ./run.sh | |
| env: | |
| ALLURE: 1 | |
| - name: Wait for report to be fully generated | |
| run: sleep 20 | |
| - name: Deploy Allure Report to GitHub Pages # <-- added this block here | |
| uses: peaceiris/actions-gh-pages@v3 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: ./allure-report |