test: cover pipeline v1 Git preflight edge cases - #863
Draft
cursor[bot] wants to merge 1 commit into
Draft
Conversation
Add regression tests for remote pipeline_v1 update preflight: incomplete git metadata error, connector_ref hydration, camelCase gitDetails mapping, base_branch on create, quoted boolean parsing, and preflight GET param forwarding. Co-authored-by: Rohan Gupta <thisrohangupta@users.noreply.github.com>
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds regression tests for remote
pipeline_v1Git Experience preflight/hydration logic merged in #856 (AIPLAT-1408). Recent merges (#856 pipeline git hydration, #835 deploy-ai-agent prompt, #859 schema sync) were inspected; the prompt and schema areas already had coverage, but several high-risk preflight branches inpipelines.tswere untested.Risky behavior now covered
REMOTEbut cannot resolve branch/repo/path/SHAs → throws an actionable error instead of sending a doomed PUT.connector_refstamped from the preflight GET intobody.git_details.gitDetails/branchName/objectIdshapes from the API.base_branchinbody.git_detailsfor new-branch flows.is_harness_code_repo: "false"is parsed correctly (agents often quote JSON booleans).connector_refis forwarded into the hydration GET.Test files added/updated
tests/registry/pipeline-v1-git.test.ts(+6 tests, 20 total in file)Why these tests materially reduce regression risk
Remote pipeline updates are a core agent workflow. The preflight path silently hydrates Git lock SHAs and location fields; regressions here surface as cryptic GitX errors (
No branch provided,__default__SHA validation) that are hard to debug. These tests lock the hydration contract and the fail-fast error when hydration cannot complete.Type of Change
Checklist
pnpm testpasses (3149 tests)pnpm typecheckpassespnpm buildpassespnpm standards:checkpassespnpm docs:checkpasses (registry/tool counts unchanged)Coding Standards (registry-driven MCP model)
N/A — test-only change.