From b974167fba36d85523eb934847dd73fa3826f31c Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 16 Dec 2025 15:13:23 +0000 Subject: [PATCH 1/2] Initial plan From d4ba144c55e9933d01db96b5f4c8c0cb11d011cb Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 16 Dec 2025 15:21:29 +0000 Subject: [PATCH 2/2] ci: eliminate massive test duplication in integration tests - Add skip_pattern support to integration test matrix - Configure catch-all groups to skip already-tested patterns - Eliminates 3,976 duplicate test executions (35.4% duplication rate) - Expected improvement: 114s per CI run (43% faster integration tests) Fixes test duplication where catch-all groups with pattern: '' run ALL tests including those already matched by specific patterns. Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com> --- .github/workflows/ci.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0a81af319df..ead3afa489a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -93,6 +93,7 @@ jobs: - name: "CLI Completion & Safe Inputs" packages: "./pkg/cli" pattern: "" # Catch-all for tests not matched by other CLI patterns + skip_pattern: "^TestCompile[^W]|TestPoutine|TestMCPInspectPlaywright|TestMCPGateway|TestMCPAdd|TestMCPInspectGitHub|TestMCPServer|TestMCPConfig|TestLogs|TestFirewall|TestNoStopTime|TestLocalWorkflow|TestProgressFlagSignature" - name: "Workflow Compiler" packages: "./pkg/workflow" pattern: "TestCompile|TestWorkflow|TestGenerate|TestParse" @@ -120,12 +121,14 @@ jobs: - name: "CMD Tests" # All cmd/gh-aw integration tests packages: "./cmd/gh-aw" pattern: "" + skip_pattern: "" # No other groups cover cmd tests - name: "Parser Remote Fetch & Cache" packages: "./pkg/parser" pattern: "TestDownloadFileFromGitHub|TestResolveIncludePath|TestDownloadIncludeFromWorkflowSpec|TestImportCache" - name: "Parser Location & Validation" packages: "./pkg/parser" pattern: "" # Catch-all for tests not matched by other Parser patterns + skip_pattern: "TestDownloadFileFromGitHub|TestResolveIncludePath|TestDownloadIncludeFromWorkflowSpec|TestImportCache" - name: "Workflow Permissions" packages: "./pkg/workflow" pattern: "TestPermissions|TestPackageExtractor|TestCollectPackagesFromWorkflow" @@ -141,6 +144,7 @@ jobs: - name: "Workflow Misc Part 2" # Remaining workflow tests packages: "./pkg/workflow" pattern: "" + skip_pattern: "TestCompile|TestWorkflow|TestGenerate|TestParse|TestMCP|TestTool|TestSkill|TestPlaywright|TestFirewall|TestValidat|TestLock|TestError|TestWarning|SafeOutputs|CreatePullRequest|OutputLabel|HasSafeOutputs|GitHub|Git|PushToPullRequest|BuildFromAllowed|Render|Bundle|Script|WritePromptText|Cache|Action|Container|Dependabot|Security|PII|TestPermissions|TestPackageExtractor|TestCollectPackagesFromWorkflow|TestExpression|TestValidateExpressionSafety|TestCheckNetworkSupport|TestValidateStrictMCPNetwork|TestJobManager|TestWorkflowStep|TestScriptRegistry|TestAgent|TestCopilot|TestCustom|TestEngine|TestModel|TestNetwork|TestOpenAI|TestProvider" concurrency: group: ci-${{ github.ref }}-integration-${{ matrix.test-group.name }} cancel-in-progress: true @@ -173,7 +177,12 @@ jobs: SAFE_NAME=$(echo "${{ matrix.test-group.name }}" | sed 's/[^a-zA-Z0-9]/-/g' | sed 's/--*/-/g') if [ -z "${{ matrix.test-group.pattern }}" ]; then - go test -v -parallel=8 -timeout=5m -tags 'integration' -json ${{ matrix.test-group.packages }} > "test-result-integration-${SAFE_NAME}.json" + # Catch-all group: run with -skip to exclude tests matched by other groups + if [ -n "${{ matrix.test-group.skip_pattern || '' }}" ]; then + go test -v -parallel=8 -timeout=5m -tags 'integration' -skip '${{ matrix.test-group.skip_pattern }}' -json ${{ matrix.test-group.packages }} > "test-result-integration-${SAFE_NAME}.json" + else + go test -v -parallel=8 -timeout=5m -tags 'integration' -json ${{ matrix.test-group.packages }} > "test-result-integration-${SAFE_NAME}.json" + fi else go test -v -parallel=8 -timeout=5m -tags 'integration' -run '${{ matrix.test-group.pattern }}' -json ${{ matrix.test-group.packages }} > "test-result-integration-${SAFE_NAME}.json" fi