Skip to content

Add workspace-scoped runtime path policy #575

Add workspace-scoped runtime path policy

Add workspace-scoped runtime path policy #575

Workflow file for this run

# ASSERT regression-related unit tests.
#
# The science workflow owns baseline-versus-treatment model runs. This workflow
# retains the broader unit-test coverage for pipeline and regression changes.
name: Regression Unit Tests
on:
pull_request:
paths:
- 'assert_ai/**'
- 'prompts/**'
- 'scripts/regression_*.py'
# The job runs the whole `tests/` tree, not just tests/regression/, so
# scoping the filter to the subdirectory let edits to top-level suites
# (e.g. tests/test_init_command.py, tests/test_library_e2e.py) reach the
# merge queue untested whenever no assert_ai/ file changed alongside them.
- 'tests/**'
# The run-assert-eval skill ships clarity_intake.py plus its own tests
# under .claude/. Without this, edits to the skill or its fixtures never
# trigger the workflow that runs them.
- '.claude/skills/**'
- 'pytest.ini'
# Dependency metadata decides what CI installs. Keep the workflow itself
# in scope so dependency-resolution fixes can verify their own change.
- 'pyproject.toml'
- 'uv.lock'
- '.github/workflows/regression.yml'
# Example dirs the unit tests genuinely load from disk (verified by
# removing each and watching the suite fail):
# tests/test_library_e2e.py reads langgraph-foundry-hosted/eval_config.yaml
# tests/test_tool_module_sandbox.py imports examples.agents.health_assistant
# Joint AgentShield + ASSERT demo: gate doc + example changes that
# claim measured eval-fix-loop numbers (see PR #43 / case study).
- 'examples/incident_triage_agent/**'
- 'examples/langgraph-foundry-hosted/**'
- 'examples/agents/**'
- 'docs/case-study-*.md'
concurrency:
group: regression-${{ github.head_ref }}
cancel-in-progress: true
jobs:
tier1-unit:
name: "Tier 1: Unit Tests"
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- uses: actions/setup-node@v4
with:
node-version: "24"
cache: "npm"
cache-dependency-path: viewer/package-lock.json
- name: Install Python dependencies
# The dev extra includes the test runner plus analysis and ACS
# dependencies exercised by the full unit-test suite. OpenTelemetry's
# API and SDK are base ASSERT dependencies, so the Phoenix server extra
# is not needed here.
run: |
python -m pip install -e ".[dev]"
- name: Check the behavior library
# Guards two things the reference library cannot enforce by itself:
# that presets stay atomic (best-practices 8.D), and that
# examples/behavior_specs/*.md never drifts from the shipped YAML.
run: python scripts/check_behavior_library.py
- name: Install viewer npm dependencies
# tests/test_viewer_*.py shell out to `node` against viewer TypeScript
# sources that import npm packages (e.g. `yaml` in artifacts.ts).
# Without `viewer/node_modules` populated the viewer harness fails
# with ERR_MODULE_NOT_FOUND.
run: npm ci --prefix viewer
- name: Run unit tests
# Both paths are required: `pytest tests/` would override the testpaths
# in pytest.ini and silently skip the skill's own suite.
run: pytest tests/ .claude/skills/run-assert-eval/tests/ -x -q