test: add coverage for agents, schema cache isolation, and Zod 4 list/get descriptions#413
Draft
cursor[bot] wants to merge 5 commits into
Draft
test: add coverage for agents, schema cache isolation, and Zod 4 list/get descriptions#413cursor[bot] wants to merge 5 commits into
cursor[bot] wants to merge 5 commits into
Conversation
Update version across package.json, both manifest files, and the release-metadata test that keeps them in sync. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> AI-Session-Id: 1b46c8db-abe4-4e9f-a38b-750362ead8ac AI-Tool: claude-code AI-Model: unknown
Expand automated architecture guardrails to cover: - Global fetch() limited to documented exceptions (HarnessClient, log-resolver CDN blobs, audit webhooks) - HarnessClient instantiation only in src/index.ts - Zod v4 import convention in tool handlers and config - Explicit openWorldHint annotations on all tool handlers - No deprecated server.tool() usage - Runtime registry contract checks (scope, identifierFields, operationPolicy) Document fetch() exceptions in docs/coding-standards.md. Co-authored-by: Rohan Gupta <thisrohangupta@users.noreply.github.com>
…apperKey scope injection Add regression tests for high-blast-radius utilities and registry paths that lacked focused coverage after recent merges: - formatBodyPreview redacts content/content_base64 before write elicitation - parseZipCsv and dashboardDataExtract handle store and deflate ZIP CSVs - connector create injects org/project scope inside bodyWrapperKey wrapper and validates bodySchema fields against the wrapped payload Co-authored-by: Rohan Gupta <thisrohangupta@users.noreply.github.com>
Co-authored-by: Rohan Gupta <thisrohangupta@users.noreply.github.com>
…list/get descriptions - Add registry tests for agent create bodyBuilder uid auto-generation and CRUD dispatch - Add cache key unit tests and live fetcher cache-hit / bundledSnapshotMatchesScope coverage - Add create-agent prompt registration and workflow contract tests - Extend harness_list/harness_get with post-registration Zod 4 description regression tests 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.
Risky behavior now covered
generateAgentUidand the createbodyBuilderauto-filluidfromname, trim edge-case punctuation, and reject bodies missing both fields. CRUD dispatch paths (list/get/create/update/delete) are verified against/gateway/agents/api/v1/agents.buildLiveSchemaCacheKeynow has unit tests proving org/project identifiers partition the cache. Live fetcher tests confirm cache hits for identical scope and that vendored project snapshots are rejected when org/project don't match bundled meta.harness_listandharness_getmirror the existingharness_executeguard, catching.describe()-before-.optional()regressions that strip LLM-facing field docs.harness_list/harness_get/harness_update) are covered.Test files added/updated
tests/registry/agents.test.tstests/tools/entity-schema-cache-keys.test.tstests/prompts/create-agent.test.tstests/tools/entity-schema-bundled.test.tsbundledSnapshotMatchesScope, cache hittests/tools/tool-handlers.test.tsWhy these tests materially reduce regression risk
Validation:
pnpm test— 2221 tests passed.