Skip to content

Refactor parser engine-include tests to table-driven testify assertions#33241

Merged
pelikhan merged 5 commits into
mainfrom
copilot/test-quality-improvement-engine-includes-test
May 19, 2026
Merged

Refactor parser engine-include tests to table-driven testify assertions#33241
pelikhan merged 5 commits into
mainfrom
copilot/test-quality-improvement-engine-includes-test

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 19, 2026

pkg/parser/engine_includes_test.go had repetitive scenario tests and mixed assertion styles, which made failures noisier and future case additions harder. This change consolidates the engine-include coverage into a single table-driven structure and standardizes assertions on testify best practices.

  • Scope: test quality refactor (no production logic changes)

    • Reworked the six TestExpandIncludesForEngines* variants into one table-driven TestExpandIncludesForEngines.
    • Preserved scenario coverage: string engine, object engine, no engine, multiple includes, optional missing include, command-based engine object.
  • Assertion standardization with testify

    • Added assert/require imports.
    • Replaced t.Fatal/t.Fatalf with require.* for setup/critical-path checks.
    • Replaced t.Errorf with assert.* for behavioral validations.
    • Added descriptive assertion messages throughout.
  • extractFrontmatterField test cleanup

    • Updated TestExtractEngineFromContent to use require.NoError + assert.Equal in each subtest.
tests := []struct {
    name             string
    includeFiles     map[string]string
    mainContent      string
    expectedLen      int
    expectedExact    map[int]string
    expectedContains map[int][]string
}{ /* scenarios */ }

engines, err := ExpandIncludesForEngines(tt.mainContent, tmpDir)
require.NoError(t, err, "Should expand includes for test case %q", tt.name)
require.Len(t, engines, tt.expectedLen, "Should return expected number of engines for test case %q", tt.name)

for idx, expected := range tt.expectedExact {
    assert.Equal(t, expected, engines[idx], "Engine %d should match expected value for test case %q", idx, tt.name)
}
for idx, fields := range tt.expectedContains {
    for _, field := range fields {
        assert.Containsf(t, engines[idx], field, "Engine %d should include field %q for test case %q", idx, field, tt.name)
    }
}

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • https://api.github.com/graphql
    • Triggering command: /usr/bin/gh gh repo view --json owner,name --jq .owner.login + "/" + .name x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh repo view --json owner,name --jq .owner.login + "/" + .name At,event,headBranch,headSha,displayTitle GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuremote2 env ters.test GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh pr list --repo github/gh-aw --state all --author app/github-actions --search created:2026-05-11T23:58:00Z..2026-05-12T00:05:00Z --limit 1 --json number --jq .[0].number GOMOD GOMODCACHE ache/go/1.25.8/xremote.origin.url (http block)
  • https://api.github.com/orgs/owner/actions/secrets
    • Triggering command: /usr/bin/gh gh api /orgs/owner/actions/secrets --jq .secrets[].name -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /orgs/owner/actions/secrets --jq .secrets[].name json Initial ode_modules/.binpkg/workflow/safe_outputs_fix_test.go ithub/workflows/go go ache/go/1.25.8/x-json gh ode_�� ithub-script/gitGOINSECURE --jq bject.type] | @tGOMODCACHE 3853959/b563/_pkgit -importcfg 3853959/b563=> infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /orgs/owner/actions/secrets --jq .secrets[].name install --package-lock-only /usr/bin/du faultBranchFromLgo faultBranchFromLenv 86102/b472/vet.c-json du -k on' --ignore-patGOINSECURE /opt/hostedtoolcGOMOD bject.type] | @tGOMODCACHE maxdepth 5 -typegit /test2.lock.yml bject.type] | @t/tmp/gh-aw-test-runs/20260519-090347-53576/test-source-field-variant-1915097596/-s gh (http block)
  • https://api.github.com/orgs/test-owner/actions/secrets
    • Triggering command: /usr/bin/gh gh api /orgs/test-owner/actions/secrets --jq .secrets[].name -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /orgs/test-owner/actions/secrets --jq .secrets[].name ithub-script/git/ref/tags/v9 /opt/hostedtoolc--jq node atlGsK9sbZnN50_Qgo -goversion ache/go/1.25.8/x-json gh ode_�� ithub-script/gitGOINSECURE --jq herFiles,CFiles,GOMODCACHE 3853959/b564/_pkgh -f ache/go/1.25.8/x/repos/actions/github-script/git/ref/tags/v9.0.0 infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /orgs/test-owner/actions/secrets --jq .secrets[].name /repos/actions/gpkg/workflow/agentic_workflow_test.go --jq ndor/bin/bash che/go-build/a5/go **/*.cjs 86102/b487/vet.c-json ay/oSZOjzL8L3jqfGO111MODULE ^Fro�� on' --ignore-patGOINSECURE /opt/hostedtoolcGOMOD herFiles,CFiles,GOMODCACHE runs/20260519-09gh -trimpath /opt/hostedtoolc/repos/actions/github-script/git/ref/tags/v9.0.0 gh (http block)
  • https://api.github.com/repos/actions/ai-inference/git/ref/tags/v1
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq [.object.sha, .object.type] | @tsv 47 -buildtags ion.lock.yml -errorsas -ifaceassert -nilfunc infocmp ortc�� runs/20260519-085528-31160/test-4142944448 stmain.go ache/node/24.14.1/x64/bin/node -json GO111MODULE 64/bin/go gh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq [.object.sha, .object.type] | @tsv "prettier" --check 'scripts/**/*.js' --ignore-path .prettierigno-s x_amd64/compile /opt/hostedtoolcache/go/1.25.8/x64/bin/go tierignore --jq sv go env licyMinIntegrityOnlymin-integrity_with_repos=public_1296676065/0remote.upstream.url GO111MODULE /usr/bin/infocmp l GOMOD GOMODCACHE infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq [.object.sha, .object.type] | @tsv "prettier" --check 'scripts/**/*.js' --ignore-paremote.origin.url infocmp /opt/hostedtoolcache/go/1.25.8/x64/bin/go tierignore sh bject.type] | @t/repos/actions/github-script/git/ref/tags/v9 go env licyMinIntegrityOnlymin-integrity_with_repos=public_1976051249/001 GO111MODULE ache/node/24.14.1/x64/bin/node l GOMOD GOMODCACHE infocmp (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v3
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv agent-persona-explorer.md /tmp/go-build3673853959/b055/vet.cfg e/git GOSUMDB GOWORK 64/bin/go e/git -uns�� artifacts-summary.md /tmp/go-build3673853959/b240/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet -json GO111MODULE 64/bin/go ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv "prettier" --write '**/*.cjs' '**/*.ts' '**/*.jsremote.upstream.url bash ache/go/1.25.8/x64/bin/go &1 ache/go/1.25.8/x-1 bject.type] | @txterm-color sh -c ExpressionCompiledOutput3396847810/001 infocmp fg re --log-level=einfocmp ache/go/1.25.8/x-1 /node sh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv "prettier" --write '**/*.cjs' '**/*.ts' '**/*.jsremote.upstream.url infocmp ache/go/1.25.8/x64/bin/go /ref/tags/v9 node sv sh -c ExpressionCompilv1.0.0 sh cfg ithub-script/gitgh sh bject.type] | @tview sh (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v5
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq [.object.sha, .object.type] | @tsv efaultBranchFromLsRemoteWithRealGitbranch_with_hyphen2318022677/001' efaultBranchFromLsRemoteWithRealGitbranch_with_hyphen2318022677/001' 64/pkg/tool/linux_amd64/link GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuconfig -uns�� outil.test /tmp/go-build3673853959/b426/vet.cfg ortcfg.link GOSUMDB GOWORK 64/bin/go WSvxw1peeV_q1ucRgQ/uj0Jsxk1t5AfUremote.origin.url (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq [.object.sha, .object.type] | @tsv 3853959/b554/_pkg_.a --format=%(objectname) 3853959/b554=> -json b/gh-aw/pkg/stat-1 64/bin/go go env mTmY/X14dOUz2TyCwBUYLmTmY l /usr/bin/git -json GO111MODULE x_amd64/vet 3853959/b554/importcfg (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq [.object.sha, .object.type] | @tsv -test.paniconexit0 -test.v=true /usr/bin/git -test.timeout=10infocmp -test.run=^Test -test.short=truexterm-color git -C /tmp/shared-actions-test2037498547 config (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v6
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv se GoFiles,IgnoredGoFiles,IgnoredOtherFiles,CFiles,CgoFiles,CXXFiles,MFiles,HFiles,FFiles,SFiles,Swapi ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet ACCEPT pkg/mod/github.cworkflow 64/bin/go ache/go/1.25.8/x--all -uns�� CommaSeparatedCoid,name,path,state /tmp/go-build367--repo ache/go/1.25.8/xowner/repo /tmp/go-build307infocmp -trimpath 64/bin/go ache/go/1.25.8/x64/pkg/tool/linuremote.origin.url (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv se 3853959/b397/vet.cfg /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linu-nolocalimports INVALID,NEW -j DROP /opt/hostedtoolcowner/host-repo GoFi�� approach-validator.md (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv g_.a /tmp/go-build3673853959/b029/vet.cfg 3853959/b287/vet.cfg GOSUMDB GOWORK 64/bin/go /opt/hostedtoolctest-owner/test-repo-31160 -uns�� jyRhJRH0j /tmp/go-build3673853959/b079/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/link /tmp/go-build307infocmp -trimpath 64/bin/go ortcfg (http block)
  • https://api.github.com/repos/actions/github-script/git/ref/tags/v8
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq [.object.sha, .object.type] | @tsv bility_SameInputSameOutput2673688121/001/stability-test.md go /usr/bin/git -json GO111MODULE x_amd64/vet git -C ithub-script/git/ref/tags/v9 config bject.type] | @tsv remote.origin.urgit GO111MODULE x_amd64/vet git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq [.object.sha, .object.type] | @tsv /tmp/gh-aw-test-runs/20260519-085528-31160/test-1129654072/.gith.github/workflows/test.md remote /usr/bin/git -json GO111MODULE x_amd64/vet git remo�� GOMODCACHE x_amd64/vet om/owner/repo.git -json GO111MODULE x_amd64/vet /tmp/go-build367--jq (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq [.object.sha, .object.type] | @tsv 482318/001 test@example.com /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOSUMDB GOWORK /sh /opt/hostedtoolcache/go/1.25.8/x--jq -ato�� 2561707520 -buildtags /usr/bin/git -errorsas -ifaceassert -nilfunc git (http block)
  • https://api.github.com/repos/actions/github-script/git/ref/tags/v9
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE 1KKmqAVRfqeK env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9 --jq [.object.sha, .object.type] | @tsv -c=4 -nolocalimports -importcfg /tmp/go-build3673853959/b484/importcfg -pack /home/REDACTED/work/gh-aw/gh-aw/pkg/constants/constants.go /home/REDACTED/work/gh-aw/gh-aw/pkg/constants/engine_constants.go env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
  • https://api.github.com/repos/actions/github-script/git/ref/tags/v9.0.0
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE CR57ehV/KUxHt1wA-buildtags env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
  • https://api.github.com/repos/actions/setup-go/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv -bool -buildtags 1/x64/bin/node -errorsas -ifaceassert -nilfunc /opt/hostedtoolcache/go/1.25.8/xconfig t-ha�� ithub/workflows/ace-editor.md -trimpath /usr/lib/git-core/git-upload-pack l main -lang=go1.25 git-upload-pack (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv npx prettier --check '**/*.cjs' '**/*.ts' '**/*.json' --ignore-path ../../../.pr**/*.json infocmp /home/REDACTED/node_modules/.bin/node ignore-path ../.infocmp ache/go/1.25.8/x-1 sv node /hom�� ulls/1 scripts/**/*.js /opt/hostedtoolcache/go/1.25.8/x64/bin/go -d --jq .go go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv 0347-53576/test-1437649771/.github/workflows gh ache/node/24.14.1/x64/bin/node ignore-path ../.infocmp 64/pkg/tool/linu-1 ker/docker-init node t-40�� sistency_GoAndJavaScript2925158640/001/test-empty-frontmatter.md scripts/**/*.js /opt/hostedtoolcache/go/1.25.8/x64/bin/go -d node /usr/bin/gh go (http block)
  • https://api.github.com/repos/actions/setup-node/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv 5528-31160/test-593917214/.github/workflows -buildtags 3853959/b342/vet.cfg -errorsas -ifaceassert -nilfunc /opt/hostedtoolc-test.v=true -ato�� runs/20260519-08-test.timeout=10m0s -buildtags e/git -errorsas -ifaceassert -nilfunc e/git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv 3853959/b528/osexitinlibrary.test -buildtags 1/x64/bin/node -errorsas -ifaceassert -nilfunc S2gg2N-X9scHQ/C0lOC29ZbsTsmn_NRyremote.upstream.url -has�� ithub/workflows/ab-testing-advisor.md -importcfg 3853959/b528/_pkg_.a -s -w -buildmode=exe git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv --all-progress-implied url /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/link --thin --delta-base-off/opt/hostedtoolcache/node/24.14.1/x64/bin/npm -q /opt/hostedtoolc--package-lock-only -o /tmp/go-build3673853959/b538/logger.test -importcfg .0/x64/bin/go -}" =~ ^tcp:// ]ls -w -buildmode=exe git (http block)
  • https://api.github.com/repos/actions/setup-node/git/ref/tags/v6
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv se 3853959/b115/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet 0 FFiles,SFiles,Swrepo ACCEPT ache/go/1.25.8/xowner/repo -ato�� CommaSeparatedCompiledOutput2518832178/001 -buildtags 1/x64/bin/node -errorsas -ifaceassert -nilfunc e/git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv se 3853959/b398/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet 4796200/b460/embgh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv /a.out /tmp/go-build3673853959/b031/vet.cfg ortcfg.link GOSUMDB WocIZyuN7jyRhJRHrepo 64/bin/go g_.a -uns�� 3853959/b501/_pkg_.a /tmp/go-build3673853959/b084/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/link /tmp/go-build307infocmp b/gh-aw/pkg/json-1 64/bin/go ache/go/1.25.8/x64/pkg/tool/linux_amd64/link (http block)
  • https://api.github.com/repos/actions/upload-artifact/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv se stmain.go ache/go/1.25.8/x64/pkg/tool/linux_amd64/link GOSUMDB FFiles,SFiles,Swrepo 64/bin/go ache/go/1.25.8/xowner/test-repo -uns�� 3853959/b502/jsonutil.test /tmp/go-build3673853959/b089/vet.cfg 1/x64/bin/node /tmp/go-build307infocmp -trimpath 64/bin/go ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv 40b8a876124972561bc8a74d80ed405cd7ca788316165a43-errorsas pkg/workflow/safe_outputs_config_generation.go fg pkg/workflow/safgh pkg/workflow/safrun pkg/workflow/safdownload ache/go/1.25.8/x5 -w 0039-43027/test-test-logs/run-5 security 64/pkg/tool/linux_amd64/vet OUTPUT -d 168.63.129.16 64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv 3428705090/001 git 1/x64/bin/node f/tags/v4 remote.origin.ur-1 sv ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile -has�� vaScript2925158640/001/test-inlined-imports-enabremote.upstream.url **/*.cjs ache/go/1.25.8/x64/pkg/tool/linux_amd64/asm **/*.json --ignore-path ../../../.pretti/repos/actions/github-script/git/ref/tags/v9 ache/go/1.25.8/x--jq (http block)
  • https://api.github.com/repos/aws-actions/configure-aws-credentials/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/aws-actions/configure-aws-credentials/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv t0 --auto 64/pkg/tool/linux_amd64/vet m0s GO111MODULE (http block)
    • Triggering command: /usr/bin/gh gh api /repos/aws-actions/configure-aws-credentials/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv GOMODCACHE go ache/go/1.25.8/x64/pkg/tool/linu-nolocalimports -json GO111MODULE 64/bin/go ache/go/1.25.8/x64/pkg/tool/linu--jq -C 3853959/b579/_pkg_.a config 3853959/b579=> remote.upstream.git b/gh-aw/pkg/typebranch x_amd64/vet git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/aws-actions/configure-aws-credentials/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv /var/run/docker.sock" GH_AW_DOCKER_HOST_PATH_PRE--limit url /usr/bin/git -errorsas -ifaceassert -nilfunc git add un_started_at, updatedAt: .updated_at, event: .event, headBranch: .head_branch, -tests /opt/hostedtoolcache/node/24.14.1/x64/bin/node -m Branch commit sh node (http block)
  • https://api.github.com/repos/azure/login/git/ref/tags/v2
    • Triggering command: /usr/bin/gh gh api /repos/azure/login/git/ref/tags/v2 --jq [.object.sha, .object.type] | @tsv sistency_GoAndJavaScript446361990/001/test-frontmatter-with-arrays.md -f 3853959/b542/_pkg_.a -- unsafe 64/bin/go gh api :latest --jq clusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle -json 90 x_amd64/vet git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/azure/login/git/ref/tags/v2 --jq [.object.sha, .object.type] | @tsv runs/20260519-090039-43027/test-1709024255 -buildtags (http block)
    • Triggering command: /usr/bin/gh gh api /repos/azure/login/git/ref/tags/v2 --jq [.object.sha, .object.type] | @tsv -bool url ache/node/24.14.1/x64/bin/node -errorsas -ifaceassert -nilfunc ache/node/24.14.1/x64/bin/node 7958�� /ref/tags/v9 --format=%(objectname) sv ath ../../../.pr/usr/lib/git-core/git on sv git (http block)
  • https://api.github.com/repos/docker/login-action/git/ref/tags/v3
    • Triggering command: /usr/bin/gh gh api /repos/docker/login-action/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv sistency_GoAndJavaScript446361990/001/test-frontmatter-with-nest-test.timeout=10m0s git-upload-pack '/tmp/TestParseDefaultBranchFromLsRemoteWithReal-test.run=^Test ache/node/24.14.1/x64/bin/node -json GO111MODULE 64/bin/go git t-73�� sistency_InlinedImports3914092565/001/inlined-a.md 3853959/b542/_testmain.go /usr/bin/infocmp remote.origin.urgit GO111MODULE x_amd64/vet infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /repos/docker/login-action/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv k/gh-aw/gh-aw/.github/workflows/agent-persona-explorer.md -buildtags /usr/lib/git-core/git -errorsas -ifaceassert -nilfunc /usr/lib/git-core/git unpa�� ithub-script/git/ref/tags/v9 -q ache/node/24.14.1/x64/bin/node ath ../../../.prgit git _modules/.bin/sh. ache/node/24.14.1/x64/bin/node (http block)
    • Triggering command: /usr/bin/gh gh api /repos/docker/login-action/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv k/gh-aw/gh-aw/.github/workflows/agent-performance-analyzer.md -buildtags (http block)
  • https://api.github.com/repos/github/gh-aw-actions/git/ref/tags/v0.1.2
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v0.1.2 --jq [.object.sha, .object.type] | @tsv /actions/secrets -buildtags r: $owner, name: $name) { hasDiscussionsEnabled } } -errorsas -ifaceassert -nilfunc /opt/hostedtoolcache/go/1.25.8/xremote.origin.url -ato�� runs/20260519-085528-31160/test-1129654072/.gith.github/workflows/test.md -buildtags /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/compile -errorsas -ifaceassert -nilfunc /opt/hostedtoolcache/go/1.25.8/x--jq (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v0.1.2 --jq [.object.sha, .object.type] | @tsv runs/20260519-090039-43027/test-source-field-variant-1138432541/.github/workflows infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v0.1.2 --jq [.object.sha, .object.type] | @tsv slug-upstream-paid,name,path,state lint:cjs (http block)
  • https://api.github.com/repos/github/gh-aw-actions/git/ref/tags/v1.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv -unreachable=false /tmp/go-build3673853959/b166/vet.cfg tartedAt,updatedAt,event,headBranch,headSha,displayTitle GOSUMDB GOWORK 64/bin/go ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet -uns�� st-1446997155/.github/workflows /tmp/go-build3673853959/b102/vet.cfg e/git-upload-pack /tmp/go-build307infocmp -trimpath 64/bin/go /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv r.test docker tcfg.link ithub-script/gitinfocmp this-image-does--1 erignore 2ilPXdvzwMEYC8X0Fy/oSZOjzL8L3jqf8Lg7GqE/vSgWVw4uconfig -c 0039-43027/test-2158869647/.github/workflows infocmp tartedAt,updatedAt,event,headBranch,headSha,displayTitle tierignore ache/go/1.25.8/x-1 ker/cli-plugins/xterm-color ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv 1475020c2056476a03d046e77d3dfd96aaa4f17104eb790cf021a505c7bf85cb-d actions/setup/js/node_modules/flatted/golang/pkg/flatted/flatted.go b1d23c789d70ab9e0febba8097b4bd3fded52d828bae04f40ac8465e8b17a902-d cmd/gh-aw/capita/usr/bin/git cmd/gh-aw/commanremote cmd/gh-aw/format-v ache/go/1.25.8/x64/pkg/tool/linurev-parse -c 0347-53576/test-3884719793/.gith@{u} cmd/gh-aw/main_help_text_test.go ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet cmd/gh-aw/versioinfocmp cmd/linters/main-1 internal/tools/axterm-color ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw-actions/git/ref/tags/v1.2.3
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv -bool -buildtags 3853959/b499/gitutil.test H_PREFIX_ARGS="--docker-host-path-prefix /tmp/gh-aw" fi echo "$GH_AW_DOCKER_HOST_PATH_PREFIX_AR -ifaceassert -nilfunc 3853959/b499/gitconfig e=/t�� t0 /tmp/go-build3673853959/b106/vet.cfg 64/pkg/tool/linux_amd64/vet m0s -trimpath (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv efaultBranchFromLsRemoteWithRealGitcustom_branch4248584126/001' efaultBranchFromLsRemoteWithRealGitcustom_branch4248584126/001' 1/x64/bin/node ithub-script/git/usr/bin/git 64/pkg/tool/linuconfig bject.type] | @t--get-regexp ache/go/1.25.8/x^remote\..*\.gh-resolved$ t-ha�� SameOutput1127861953/001/stability-test.md infocmp ache/go/1.25.8/x64/pkg/tool/linux_amd64/link tierignore ache/go/1.25.8/x-1 bject.type] | @txterm-color ache/go/1.25.8/x64/pkg/tool/linu^remote\..*\.gh-resolved$ (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv sRemoteWithRealGitcustom_branch3867483806/001 sRemoteWithRealGitcustom_branch3867483806/002/work cfg r code style"; t/usr/bin/git remote.origin.urconfig /usr/bin/gh ache/go/1.25.8/x^remote\..*\.gh-resolved$ /opt�� /ref/tags/v9 --write sv --ignore-path .prettierignore --log-level=erro/tmp/TestCollectWorkflowFiles_TransitiveImports3462826007/001 ache/go/1.25.8/xremote (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --limit 100 --created >=2026-05-12 GOMOD GOMODCACHE 64/pkg/tool/linuTest User env matter-with-arrays.md oFiles,IgnoredOtherFiles,CFiles,unsafe 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --limit 100 --created >=2026-04-19 GOMOD GOMODCACHE 64/pkg/tool/linuremote.origin.url env ed-imports-enabled-with-body-content.md mLsRemoteWithRealGitbranch_with_hyphen2318022677/001' 64/pkg/tool/linux_amd64/vet GOINSECURE igFiles,SwigCXXF/tmp/js-hash-test-3112524718/test-hash.js GOMODCACHE 64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --limit 100 --created >=2026-02-18 GOMOD GOMODCACHE 64/pkg/tool/linuremote.origin.url env ed-imports-enabled-with-body-content.md GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/1/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/1/artifacts --jq .artifacts[].name GO111MODULE .test GOINSECURE GOMOD GOMODCACHE .test 6738�� y_only_defaults_repo3782508377/0remote.origin.url 3853959/b053/vet.cfg x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh run download 1 --dir test-logs/run-1 .cfg 64/pkg/tool/linu-importcfg GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuremote.origin.url (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/1/artifacts --jq .artifacts[].name 3fa8caf7a003f910e 64/bin/go **/*.json --ignore-path erignore sh ache�� b/workflows /usr/bin/git ache/node/24.14.1/x64/bin/node rkflow/js/**/*.jgit dUCKHpB/wl0kuDe9config erignore cp (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12345/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12345/artifacts --jq .artifacts[].name GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE sL3wPau/bPNgpHy_origin (http block)
    • Triggering command: /usr/bin/gh gh run download 12345 --dir test-logs/run-12345 GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE kK/TWhNdG8HkMg5Gupstream (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12345/artifacts --jq .artifacts[].name git 64/bin/go rt DOCKER_HOST="git remote.origin.urremote /usr/bin/git sh -c mpiledOutput1933588872/001 /usr/bin/git /snap/bin/bash rror ^remote\..*\.gh-config bject.type] | @tuser.name bash (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/1234567890
    • Triggering command: /usr/bin/gh gh api repos/{owner}/{repo}/actions/runs/1234567890 --jq {databaseId: .id, number: .run_number, url: .html_url, status: .status, conclusion: .conclusion, workflowName: .name, workflowPath: .path, createdAt: .created_at, startedAt: .run_started_at, updatedAt: .updated_at, event: .event, headBranch: .head_branch, -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api repos/{owner}/{repo}/actions/runs/1234567890 --jq {databaseId: .id, number: .run_number, url: .html_url, status: .status, conclusion: .conclusion, workflowName: .name, workflowPath: .path, createdAt: .created_at, startedAt: .run_started_at, updatedAt: .updated_at, event: .event, headBranch: .head_branch, 2d34fb9cc97f75e3-d --jq 8d519d9/node_modules/.bin/pretti../../../.prettierignore --objects url /opt/hostedtoolc-json gh api th .prettierignoGOINSECURE --jq ode_modules/.binGOMODCACHE -bool -buildtags om/testowner/tes/repos/actions/github-script/git/ref/tags/v9 infocmp (http block)
    • Triggering command: /usr/bin/gh gh api repos/{owner}/{repo}/actions/runs/1234567890 --jq {databaseId: .id, number: .run_number, url: .html_url, status: .status, conclusion: .conclusion, workflowName: .name, workflowPath: .path, createdAt: .created_at, startedAt: .run_started_at, updatedAt: .updated_at, event: .event, headBranch: .head_branch, e3fbec763980c15f-d sh ules/.bin/sh "prettier" --chego infocmp /opt/hostedtoolc-json git add th .prettierignoGOINSECURE go x86_64/git licyMinIntegrityinfocmp GO111MODULE /usr/bin/git infocmp (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12346/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12346/artifacts --jq .artifacts[].name GO111MODULE 64/pkg/tool/linu-buildmode=exe GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuorigin (http block)
    • Triggering command: /usr/bin/gh gh run download 12346 --dir test-logs/run-12346 .cfg 64/pkg/tool/linu-nilfunc GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linumyorg (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12346/artifacts --jq .artifacts[].name git 64/bin/go /ref/tags/v9 64/pkg/tool/linuremote sv sh -c mpiledOutput1933588872/001 /usr/bin/git /home/REDACTED/.local/bin/bash rror VAsfaec/Pi1C9UClconfig sv bash (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/2/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/2/artifacts --jq .artifacts[].name GO111MODULE sole.test GOINSECURE GOMOD GOMODCACHE sole.test 6738�� y_only_defaults_repo3782508377/001 3853959/b146/vet.cfg x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh run download 2 --dir test-logs/run-2 3853959/b014/vet-c=4 64/pkg/tool/linu-nolocalimports GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuupstream env edOutput4052201435/001 GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/2/artifacts --jq .artifacts[].name **/*.cjs 64/bin/go **/*.json --ignore-path erignore sh -c (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/3/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/3/artifacts --jq .artifacts[].name .cfg util.test GOINSECURE GOMOD GOMODCACHE util.test 6738�� y_with_explicit_repo1385360868/001 GO111MODULE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/xTest User (http block)
    • Triggering command: /usr/bin/gh gh run download 3 --dir test-logs/run-3 .cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/xorigin env edOutput4052201435/001 GO111MODULE ck GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/xremote.origin.url (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/3/artifacts --jq .artifacts[].name **/*.cjs 64/bin/go **/*.json --ignore-path ode-gyp-bin/sh sh ache�� b/workflows 1/x64/bin/npm k/gh-aw/gh-aw/actions/setup/js/node_modules/.bin/sh rkflow/js/**/*.jgit 64/pkg/tool/linuremote erignore /bin/sh (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/4/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/4/artifacts --jq .artifacts[].name GO111MODULE stants.test GOINSECURE GOMOD GOMODCACHE stants.test 6738�� y_with_explicit_go1.25.8 3853959/b145/vet-c=4 .cfg GOINSECURE igFiles,SwigCXXFinit GOMODCACHE ache/go/1.25.8/x/tmp/go-build3673853959/b586/_testmain.go (http block)
    • Triggering command: /usr/bin/gh gh run download 4 --dir test-logs/run-4 .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE igFiles,SwigCXXFremote GOMODCACHE 64/pkg/tool/linuorigin env mpiledOutput2518832178/001 GO111MODULE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu-importcfg (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/4/artifacts --jq .artifacts[].name **/*.cjs 64/bin/go **/*.json --ignore-path erignore sh -c te '../../../**/*.json' '!../../../pkg/workflow/GOSUMDB infocmp k/gh-aw/gh-aw/actions/node_modules/.bin/sh ithub-script/gitgit x_amd64/asm bject.type] | @tsv /bin/sh (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/5/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/5/artifacts --jq .artifacts[].name GO111MODULE 64/pkg/tool/linux_amd64/compile GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuremote.origin.url (http block)
    • Triggering command: /usr/bin/gh gh run download 5 --dir test-logs/run-5 .cfg 64/pkg/tool/linu-nilfunc GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuorigin (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/5/artifacts --jq .artifacts[].name **/*.cjs 64/bin/go **/*.json --ignore-path erignore sh ache�� "prettier" --write '../../../**/*.json' '!../../remote.upstream.url /usr/bin/git k/gh-aw/gh-aw/actions/setup/js/node_modules/.bin/sh rkflow/js/**/*.jgit ^remote\..*\.gh-init erignore cp (http block)
  • https://api.github.com/repos/github/gh-aw/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path h3783582596/001' h3783582596/001' x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-workflow-12345 --limit 100 GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-workflow-12345 --limit 6 GOMOD GOMODCACHE 64/pkg/tool/linustatus (http block)
  • https://api.github.com/repos/github/gh-aw/contents/.github/workflows/shared/reporting.md
    • Triggering command: /tmp/go-build3673853959/b475/cli.test /tmp/go-build3673853959/b475/cli.test -test.testlogfile=/tmp/go-build3673853959/b475/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /tmp/go-build13686102/b475/cli.test /tmp/go-build13686102/b475/cli.test -test.testlogfile=/tmp/go-build13686102/b475/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true /ref/tags/v9 -test.v=true sv git conf�� user.email test@example.com.prettierignore tions/node_modules/.bin/node -o l 3853959/b558/str-json infocmp (http block)
    • Triggering command: /tmp/go-build254539837/b475/cli.test /tmp/go-build254539837/b475/cli.test -test.testlogfile=/tmp/go-build254539837/b475/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true :2375" GH_AW_DOCnode gh /home/REDACTED/.doprettier node /opt�� ath ../../../.pr--ignore-path --package-lock-o.prettierignore sv '/tmp/TestParseDgo '/tmp/TestParseDenv 86102/b474/vet.c-json sed (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v0.47.4
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v0.47.4 --jq [.object.sha, .object.type] | @tsv -test.paniconexit0 l /usr/bin/git -test.timeout=10infocmp -test.run=^Test -test.short=truexterm-color git -C /tmp/TestGuardPolicyMinIntegrityOnlymin-integrity_only_defaults_repo3782508377/0remote.upstream.gh l /tmp/go-build3673853959/b549/semverutil.test remote.upstream.infocmp GO111MODULE x_amd64/vet /tmp/go-build3673853959/b549/sem--jq (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v0.47.4 --jq [.object.sha, .object.type] | @tsv runs/20260519-090039-43027/test-4015256334/.github/workflows show t :-}" =~ ^tcp:// infocmp GOWORK 64/bin/node /opt/hostedtoolcache/go/1.25.8/x--jq -ato�� -bool -buildtags /usr/bin/git -errorsas -ifaceassert -nilfunc git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v0.47.4 --jq [.object.sha, .object.type] | @tsv tcp://172.30.0.5:2375" GH_AW_DOCKER_HOST_PATH_PREFIX_ARGS="" if [[ "${DOCKER_HOST:-}" =~ ^tcp://git show /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOSUMDB GOWORK sv /opt/hostedtoolcache/go/1.25.8/x--jq -ato�� /ref/tags/v9.0.0 -buildtags sv -errorsas -ifaceassert -nilfunc git (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v1.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv /ref/tags/v9.0.0 GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linutest@example.com env -json piler}} x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv xterm-color e/git 3ac4c6c4c7284db0-d ignore -goversion /usr/bin/git infocmp ode_�� '**/*.ts' '**/*.remote.origin.url git 1/x64/bin/sh /v1.0.0 resolved$ sv infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv 6640345a:pkg/parser/engine_includes_test.go --jq bject.type] | @tsv /tmp/gh-aw-test-git ithub/gh-aw/sess-C /opt/hostedtoolc/tmp/gh-aw-test-runs/20260519-090347-53576/test-3864495553/.github/workflows infocmp ode_�� lGitbranch_with_hyphen2973735448/001' lGitbranch_with_hyphen2973735448/001' rgo/bin/sh -bool l /usr/bin/git infocmp (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v1.2.3
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuremote.upstream.url (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv iant-1138432541/.github/workflows OVeUyFlVlSS3Z/Zh6JeYQXZOMeguq2Hg--ignore-path 1/x64/lib/node_modules/npm/node_../../../.prettierignore nore 3853959/b558/_te-1 3853959/b580/_pkxterm-color infocmp -1 th .prettierignore node de_modules/.bin/sh /ref/tags/v9 (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv xterm-color git 1/x64/bin/npx runs/20260519-09infocmp /tmp/TestParseDe-1 kflows/test.lockxterm-color gh api th .prettierignore --jq rgo/bin/git -v (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v2.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env " GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuconfig (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuconfig (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE lWYp1ttTHFpX env -json .cfg 64/pkg/tool/linu-nolocalimports GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuremote.origin.url (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v3.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq [.object.sha, .object.type] | @tsv Gitmaster_branch-test.timeout=10m0s Gitmaster_branch-test.run=^Test x_amd64/vet GOINSECURE GOMOD GOMODCACHE mDRmydbNI-g3 env -json GO111MODULE 64/pkg/tool/linu-lang=go1.25 GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linu--jq (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq [.object.sha, .object.type] | @tsv iant-3090669012/.github/workflows --jq node nore remote ache/node/24.14./tmp/gh-aw-test-runs/20260519-090039-43027/test-334728853/.github/workflows gh ules�� y-frontmatter.mdremote.origin.url --jq 64/bin/sh GOMODCACHE x_amd64/vet /opt/hostedtoolc/tmp/gh-aw-test-runs/20260519-090039-43027/test-2136423900/.github/workflows gh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq [.object.sha, .object.type] | @tsv json' --ignore-path ../../../.pr**/*.json --jq bject.type] | @tsv y --revs me: String!) { /tmp/TestHashStability_SameInputSameOutput1535815772/001/stability-test.md infocmp 1/x6�� th .prettierignore git tions/setup/js/node_modules/.binGOMODCACHE /ref/tags/v9 config sv infocmp (http block)
  • https://api.github.com/repos/github/gh-aw/issues/17
    • Triggering command: /usr/bin/gh gh api repos/github/gh-aw/issues/17 VpJv3m8ccLa- env -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api repos/github/gh-aw/issues/17 infocmp -1 dceea6b3142795cc-d go ndor/bin/sh formatted. Run 'go /dev/null 3853959/b566/tes-json infocmp -1 .js' --ignore-paGOINSECURE 3853959/b566/tesGOMOD tions/node_modulGOMODCACHE t0 go (http block)
    • Triggering command: /usr/bin/gh gh api repos/github/gh-aw/issues/17 x_amd64/asm /opt�� c9e4c2d9127a9e9e-d -maxdepth /usr/bin/wc -type d -name wc -l ithub-script/gitGOINSECURE go bject.type] | @tGOMODCACHE /ref/tags/v9 url sv gh (http block)
  • https://api.github.com/repos/google-github-actions/auth/git/ref/tags/v2
    • Triggering command: /usr/bin/gh gh api /repos/google-github-actions/auth/git/ref/tags/v2 --jq [.object.sha, .object.type] | @tsv ithub-script/git/ref/tags/v9 go bject.type] | @tsv -json GO111MODULE 64/bin/go git -C /tmp/gh-aw-test-runs/20260519-085528-31160/test-410369311/.githu--detach config /usr/bin/gh remote.origin.urhead GO111MODULE x_amd64/vet gh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/google-github-actions/auth/git/ref/tags/v2 --jq [.object.sha, .object.type] | @tsv runs/20260519-090039-43027/test-1709024255 -buildtags t -errorsas -ifaceassert -nilfunc git push�� origin develop /usr/bin/gh .github/workflowhead git de_modules/.bin//tmp/gh-aw/aw-master.patch gh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/google-github-actions/auth/git/ref/tags/v2 --jq [.object.sha, .object.type] | @tsv k/gh-aw/gh-aw/.github/workflows/ace-editor.md -buildtags /usr/bin/git -errorsas -ifaceassert -nilfunc git push�� ithub-script/git/ref/tags/v9 develop bject.type] | @tsv .github/workflowhead e/git sv git (http block)
  • https://api.github.com/repos/nonexistent/action/git/ref/tags/v999.999.999
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq [.object.sha, .object.type] | @tsv 1995169812 3853959/b205/vet.cfg $name) { hasDiscussionsEnabled } } GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet env til.go til_test.go x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq [.object.sha, .object.type] | @tsv /repos/actions/github-script/git/ref/tags/v9 --jq node mpleWorkflow3431git x_amd64/vet /usr/bin/infocmp/tmp/gh-aw-test-runs/20260519-090039-43027/test-525701220/.github/workflows gh 2485�� '**/*.ts' '**/*.remote.origin.url --jq ndor/bin/sh xterm-color l ache/node/24.14.1/x64/bin/node gh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq [.object.sha, .object.type] | @tsv 6640345a:pkg/parser/engine_includes_test.go --jq 64/bin/sh 122814571/001 l /opt/hostedtoolc/tmp/gh-aw-test-runs/20260519-090347-53576/test-1202283390/.github/workflows infocmp -1 '**/*.ts' '**/*.json' --ignore-p-p /opt/hostedtoolcache/go/1.25.8/xmain ules/.bin/node -bool l /usr/bin/git infocmp (http block)
  • https://api.github.com/repos/nonexistent/repo/actions/runs/12345
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion GOINSECURE igFiles,SwigCXXF-1 GOMODCACHE 64/pkg/tool/linux_amd64/link (http block)
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion /ref/tags/v9 repos/{owner}/{rconfig th: .path, creatuser.email bash ache�� --noprofile git cal/bin/sh ignore-path .././usr/bin/git Test User sv sh (http block)
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion /tmp/gh-aw-test-git rev-parse /usr/bin/git git rev-�� 3017337659 git ow.lock.yml sv url /usr/bin/infocmp/repos/actions/github-script/git/ref/tags/v9 node (http block)
  • https://api.github.com/repos/org/repo/pulls/1
    • Triggering command: /usr/bin/gh gh api repos/org/repo/pulls/1 go 01 -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api repos/org/repo/pulls/1 64/bin/gofmt api 7db701df7c4d70e3-d _generation.go bin/sh _helpers.go _helpers_test.goenv repo_config_test-json t_create_issue_tGO111MODULE t_ma�� .js' --ignore-paGOINSECURE s_protocol_validGOMOD s_validation_tesGOMODCACHE c_allowed_repos_gh (http block)
    • Triggering command: /usr/bin/gh gh api repos/org/repo/pulls/1 gh api 2daca78344939627-d rk sv 3 scripts/**/*.js 1/x64/bin/node sed ode_�� (http block)
  • https://api.github.com/repos/owner/repo/actions/secrets
    • Triggering command: /usr/bin/gh gh api /repos/owner/repo/actions/secrets --jq .secrets[].name -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/owner/repo/actions/secrets --jq .secrets[].name from .github/aw cmd/gh-aw/version_test.go Test User de_modules/.bin/internal/tools/actions-build/main.go /tmp/go-build367go -trimpath t gh tion�� on' --ignore-patGOINSECURE --jq es/.bin/node t0 -trimpath (http block)
    • Triggering command: /usr/bin/gh gh api /repos/owner/repo/actions/secrets --jq .secrets[].name ath ../../../.prettierignore --package-lock-only 64/bin/bash che/go-build/a3/go infocmp 86102/b473/vet.c-json git form�� on' --ignore-patGOINSECURE --stdout 1/x64/bin/git /ref/tags/v9 -trimpath sv gh (http block)
  • https://api.github.com/repos/owner/repo/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-remote-workflow --limit 30 --repo owner/repo x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh workflow list --repo owner/repo --json name,path,state x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile 6738�� se 3853959/b252/vet.cfg x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
  • https://api.github.com/repos/test-owner/test-repo/actions/secrets
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name -json GO111MODULE x_amd64/asm GOINSECURE GOMOD GOMODCACHE x_amd64/asm env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name o actions/setup-cli/install.sh..**/*.ts infocmp _modules/.bin/node runs/20260519-08go stmain.go ache/node/24.14.-json gh ode_�� ithub-script/gitGOINSECURE --jq tions/setup/js/nGOMODCACHE bility_SameInputgit --json /usr/bin/git infocmp (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name /repos/actions/github-script/git/ref/tags/v9 --jq /usr/bin/wc ry=1 **/*.ts (http block)
  • https://api.github.com/repos/test/repo
    • Triggering command: /usr/bin/gh gh api /repos/test/repo --jq .default_branch se 3853959/b101/vet.cfg 64/pkg/tool/linux_amd64/compile GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuorigin 3853�� -json 3853959/b070/_testmain.go ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/xsh (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test/repo --jq .default_branch ck '**/*.cjs' '**/*.ts' '**/*.json' --ignore-path ../../../.prettierignore gh ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile ithub-script/gitgh test-owner/test-api (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test/repo --jq .default_branch 3428705090/001 gh ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile /repos/actions/ginfocmp --jq /usr/bin/git ache/go/1.25.8/x64/pkg/tool/linutest-branch /hom�� (http block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title [WIP] Improve test quality for pkg/parser/engine_includes_test.go Refactor parser engine-include tests to table-driven testify assertions May 19, 2026
Copilot AI requested a review from gh-aw-bot May 19, 2026 09:14
@pelikhan pelikhan marked this pull request as ready for review May 19, 2026 09:14
Copilot AI review requested due to automatic review settings May 19, 2026 09:14
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Refactors pkg/parser/engine_includes_test.go to consolidate repetitive engine-include scenarios into a single table-driven test and standardize assertions using testify (require for critical checks, assert for validations).

Changes:

  • Consolidated multiple TestExpandIncludesForEngines* variants into one table-driven TestExpandIncludesForEngines.
  • Standardized assertion style across the file using github.com/stretchr/testify/assert and require.
  • Updated TestExtractEngineFromContent subtests to use require.NoError + assert.Equal.
Show a summary per file
File Description
pkg/parser/engine_includes_test.go Refactors engine include tests into a table-driven structure and standardizes assertions with testify.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 1/1 changed files
  • Comments generated: 0

@pelikhan pelikhan merged commit 5eaa27a into main May 19, 2026
70 checks passed
@pelikhan pelikhan deleted the copilot/test-quality-improvement-engine-includes-test branch May 19, 2026 09:21
@github-actions github-actions Bot mentioned this pull request May 19, 2026
Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skills-Based Review 🧠

Applied /tdd based on this test quality refactor.

Key Themes

  1. Assertion style inconsistency: Mixes require and assert without clear distinction between setup vs validation
  2. Missing edge case coverage: No negative test cases for malformed engines or invalid JSON
  3. Lost test isolation context: Consolidation removed descriptive test names that communicated intent

Positive Highlights

  • ✅ Excellent move to table-driven tests — much more maintainable
  • ✅ Good use of testify/require for file I/O operations that must succeed
  • ✅ Clear test case naming with the name field
  • ✅ Removes significant code duplication (~170 lines reduced)

Verdict

Requesting changes on the assertion style and missing edge case coverage. The refactor direction is solid, but needs refinement before merge.

Note

🔒 Integrity filter blocked 1 item

The following item was blocked because it doesn't meet the GitHub integrity level.

  • #33241 pull_request_read: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".

To allow these resources, lower min-integrity in your GitHub frontmatter:

tools:
  github:
    min-integrity: approved  # merged | approved | unapproved | none

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · ● 3.6M

includeFiles map[string]string
mainContent string
expectedLen int
expectedExact map[int]string
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/tdd] The expectedExact and expectedContains maps use int keys for indices, but the test cases only validate index 0 or 1. This design assumes engines are returned in include order, but that's not explicitly documented or guaranteed.

Consider either:

  1. Add a comment documenting the ordering guarantee:
// expectedExact validates engines by index (engines returned in include directive order)
expectedExact map[int]string
  1. Or make it order-independent by validating the set of engines instead of positional:
expectedEngines []string  // Any order
for _, expected := range tt.expectedEngines {
    assert.Contains(t, engines, expected)
}

Option 2 is more robust if include processing order ever changes.

"github.com/stretchr/testify/require"
)

func TestExpandIncludesForEngines(t *testing.T) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/tdd] The table structure handles success cases well, but there's no field for expected errors. Consider adding negative test cases for:

  • Malformed engine YAML (e.g., engine: [invalid, list])
  • Invalid JSON in object engines
  • Circular include references
  • File read errors (beyond missing optional includes)

Add an expectedErr string field and a few failure scenarios:

{
    name: "malformed engine yaml",
    includeFiles: map[string]string{
        "bad.md": `---\nengine: [1, 2, 3]\n---`,
    },
    mainContent: "`@include` bad.md",
    expectedErr: "invalid engine format",
}

Testing error paths prevents regressions when error handling changes.

if result != tt.expected {
t.Errorf("Expected %q, got %q", tt.expected, result)
}
require.NoError(t, err, "Should extract engine field without error for case %q", tt.name)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/tdd] Excellent refactor of TestExtractFrontmatterFieldEngine to use assert consistently and remove the duplication. This is exactly the right direction.

One minor improvement: the error message uses %q for tt.name redundantly (same issue as the other test). Simplify to:

require.NoError(t, err, "Should extract engine field without error")
assert.Equal(t, tt.expected, result, "Extracted engine should match expected value")

The subtest name already provides case context.

expectedContains: map[int][]string{
0: {`"id":"claude"`, `"model":"claude-3-5-sonnet-20241022"`, `"max-turns":5`},
},
},
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/tdd] require.NoError is used here for the function-under-test, but this should use assert.NoError instead. Follow the pattern:

  • require.* — Setup that must succeed (file writes, temp dirs)
  • assert.* — Actual test validations (the SUT behavior)

This line tests ExpandIncludesForEngines itself, so it's a validation, not setup:

assert.NoError(t, err, "Should expand includes for test case %q", tt.name)

Using require here stops the entire test suite on first failure rather than collecting all failing scenarios.

},
},
{
name: "include without engine",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/tdd] The error message includes %q for tt.name, but test failures already include the subtest name from t.Run(tt.name, ...). This creates redundant output:

--- FAIL: TestExpandIncludesForEngines/single_string_engine
    Should expand includes for test case "single string engine"

Simplify to:

assert.NoError(t, err, "Should expand includes without error")

The test runner already provides full context via the subtest hierarchy.

{
name: "include without engine",
includeFiles: map[string]string{
"include-no-engine.md": `---
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/tdd] This assertion uses require.Len, but the actual validation (engines content) comes after. If the length is wrong, the subsequent assertions will panic with index out of bounds. This is the correct use of require — good catch!

However, consider adding a more descriptive message:

require.Len(t, engines, tt.expectedLen, 
    "Engine count mismatch - check include file parsing")

This helps differentiate length failures from content failures when debugging.

@github-actions
Copy link
Copy Markdown
Contributor

🧪 Test Quality Sentinel Report

Test Quality Score: 100/100

Excellent test quality

Metric Value
New/modified tests analyzed 2
✅ Design tests (behavioral contracts) 2 (100%)
⚠️ Implementation tests (low value) 0 (0%)
Tests with error/edge cases 2 (100%)
Duplicate test clusters 0
Test inflation detected No (net -95 lines)
🚨 Coding-guideline violations 0

Test Classification Details

Test File Classification Issues Detected
TestExpandIncludesForEngines pkg/parser/engine_includes_test.go:15 ✅ Design None — excellent behavioral coverage
TestExtractEngineFromContent pkg/parser/engine_includes_test.go:194 ✅ Design None — covers all format variants

Refactoring Summary

This PR consolidates 5 separate test functions into a single table-driven test (TestExpandIncludesForEngines), while enhancing TestExtractEngineFromContent with additional edge cases:

Before (5 separate functions):

  • TestExpandIncludesForEnginesObjectFormat
  • TestExpandIncludesForEnginesNoEngine
  • TestExpandIncludesForEnginesMultipleIncludes
  • TestExpandIncludesForEnginesOptionalMissing
  • TestExpandIncludesForEnginesWithCommand

After (1 table-driven function with 6 subtests):

  • single string engine
  • object format engine
  • include without engine
  • multiple includes
  • optional include missing file
  • object engine with command

Key improvements:

  • ✅ Follows project guideline: table-driven tests are the preferred pattern
  • ✅ Adds descriptive assertion messages (require.NoError, assert.Equal, assert.Containsf all include context)
  • ✅ Reduces code duplication (113 additions, 208 deletions = -95 net lines)
  • ✅ Maintains complete behavioral coverage across all original test cases
  • ✅ No mocks introduced (tests real file I/O and frontmatter parsing)

Behavioral Contracts Verified

TestExpandIncludesForEngines

What it enforces: The ExpandIncludesForEngines function must correctly:

  • Extract engine configurations from @include directives
  • Preserve both string (engine: codex) and object (engine: {id: claude, model: ...}) formats
  • Handle missing engines gracefully (return empty list)
  • Process multiple includes in order
  • Skip optional includes when files are missing (@include?)
  • Extract complex object fields (command, version, max-turns)

Edge cases covered:

  • ✅ String engine format
  • ✅ Object engine format with nested fields
  • ✅ Include without engine field
  • ✅ Multiple includes in sequence
  • ✅ Optional include with missing file
  • ✅ Object engine with custom command path

TestExtractEngineFromContent

What it enforces: The extractFrontmatterField function must correctly:

  • Extract engine field from YAML frontmatter
  • Return string format for simple engines ("claude")
  • Return JSON object for complex engines ({"id":"codex","model":"gpt-4"})
  • Return empty string when engine field is absent
  • Handle markdown without frontmatter

Edge cases covered:

  • ✅ String engine
  • ✅ Object engine
  • ✅ No engine field
  • ✅ No frontmatter

Language Support

Tests analyzed:

  • 🐹 Go (*_test.go): 2 tests — unit (//go:build !integration)

Verdict

Check passed. 0% of tests are implementation tests (threshold: 30%). This is an exemplary test refactoring that follows all project guidelines:

  • Table-driven pattern (preferred approach)
  • Descriptive assertion messages on all assertions
  • Comprehensive edge case coverage
  • No mock libraries (tests real interactions)
  • Net code reduction while maintaining coverage
  • Tests behavioral contracts, not implementation details

📖 Understanding Test Classifications

Design Tests (High Value) verify what the system does:

  • Assert on observable outputs, return values, or state changes
  • Cover error paths and boundary conditions
  • Would catch a behavioral regression if deleted
  • Remain valid even after internal refactoring

Implementation Tests (Low Value) verify how the system does it:

  • Assert on internal function calls (mocking internals)
  • Only test the happy path with typical inputs
  • Break during legitimate refactoring even when behavior is correct
  • Give false assurance: they pass even when the system is wrong

Goal: Shift toward tests that describe the system's behavioral contract — the promises it makes to its users and collaborators.

🧪 Test quality analysis by Test Quality Sentinel · ● 7.3M ·

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Test Quality Sentinel: 100/100. Test quality is excellent — 0% of tests are implementation tests (threshold: 30%). This is an exemplary test refactoring that follows all project guidelines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[testify-expert] Improve Test Quality: pkg/parser/engine_includes_test.go

4 participants