Skip to content

Unit Tests

Unit Tests #15

Workflow file for this run

name: Unit Tests
on:
workflow_run:
workflows: ["Build"]
types: [completed]
permissions:
actions: read
contents: read
jobs:
unit-tests:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
ref: ${{ github.event.workflow_run.head_sha }}
submodules: recursive
- name: Setup Build Tools
uses: ./.github/actions/setup-build-tools
- name: Download build artifacts
env:
GH_TOKEN: ${{ github.token }}
run: gh run download ${{ github.event.workflow_run.id }} --repo ${{ github.repository }} --name stagehand-build-artifacts --dir .
- name: Restore unit test executable permissions
shell: bash
run: chmod +x tests/unit/build/stagehand_tests || true
- name: Run unit tests
run: python scripts/run_unit_tests.py