Skip to content

CI checks

Chris Dowin edited this page Oct 8, 2026 · 3 revisions

CI checks

3 checks, in 1 composite action: cdowin/agentic-sdlc/checks@v4.0.0. Use it as a step of a job you already have. GitHub bills each hosted job as 1 minute at least, so 3 jobs of 5 seconds cost 3 minutes. 1 step costs nothing extra.

Use 2 workflows. The required check runs context-budget and test-budget. A second workflow, not required, runs issue-link. A required check must not run on the PR edited event. A re-run with the build skipped would turn it green over a red run.

# check.yml: the required check
on:
  pull_request:
    types: [opened, synchronize, reopened, ready_for_review]
jobs:
  check:
    if: github.event.pull_request.draft != true   # a draft PR runs nothing
    runs-on: ubuntu-latest
    timeout-minutes: 10
    steps:
      - uses: actions/checkout@v5
        with:
          fetch-depth: 0                          # test-budget diffs against the PR base
      - uses: cdowin/agentic-sdlc/checks@v4.0.0
        with:
          checks: context-budget test-budget
      - run: make test                            # your build and tests
# issue-link.yml: not required; a body edit re-checks only the body
on:
  pull_request:
    types: [opened, edited, reopened, ready_for_review]
jobs:
  issue-link:
    if: github.event.pull_request.draft != true && github.actor != 'dependabot[bot]'
    runs-on: ubuntu-latest
    timeout-minutes: 5
    steps:
      - uses: cdowin/agentic-sdlc/checks@v4.0.0
        with:
          checks: issue-link
Check Behaviour Inputs
context-budget Fails when an always-loaded doc is over budget. claude_md_max (200), agents_md_max (100), rules_max (400), warn_only
test-budget Warns when a PR adds more than ratio (1.5) test lines per code line, or tests with no code. Never fails. Runs on PR events only. test_globs, ratio
issue-link Fails when the PR body has no Closes #N, Fixes #N, Part of #N, Part of owner/repo#N or Issue: none (. Runs on PR events only. On an edited event it runs only when the body changed. none

checks selects the checks, space-separated. The default is all 3.

The 3 reusable workflows under .github/workflows/ (context-budget.yml, test-budget.yml, issue-link.yml) still work in v3.x. They are deprecated, and v4 removes them.

The hooks are early warnings inside each tool. These checks enforce the rules for every provider. See Hooks reference.

Clone this wiki locally