Skip to content

Suggested test: copilot/create-pull-request-auto-merge-strategy #10527

Open

Description

@github-actions

Motivation

github/gh-aw#49412 — safe-outputs.create-pull-request.auto-merge now accepts explicit merge strategies (squash, merge, rebase) in addition to the existing boolean, mapping to GraphQL PullRequestMergeMethod for enablePullRequestAutoMerge. Fixes github/gh-aw#49377.

Proposed test

  • Workflow file: test-copilot-create-pull-request-auto-merge.md
  • Trigger: workflow_dispatch
  • Engine: copilot
  • Safe output: create-pull-request with auto-merge: squash
  • Variant: standard

Minimal test prompt sketch

Copy test-copilot-create-pull-request.md's structure, add auto-merge: squash under safe-outputs.create-pull-request, and use a samples: block so it's deterministic. The agent creates a small PR; assertion is that the compiled lock file/PR request includes the auto-merge GraphQL call with the squash strategy.

New fixtures or secrets needed

None — reuses the main repo. Auto-merge itself may require branch protection/settings enabling auto-merge on githubnext/gh-aw-test; verify this is already enabled (existing PR tests don't need it since they don't request auto-merge).

Notes

No existing test exercises auto-merge at all (checked existing-tests.json and create-pull-request* variants — none reference it). If native GitHub auto-merge can't actually complete in a test repo without additional approvals, this test may only be able to assert the safe-output request succeeded, not that the PR actually merged.

Generated by 🔍 Suggest New E2E Tests · auto · 30.2 AIC · ⌖ 8.86 AIC · ⊞ 8.3K · ◷

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions