Skip to content

test: add FME extractor and feature-flag-rollout prompt coverage - #853

Draft
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/missing-test-coverage-cb6c
Draft

test: add FME extractor and feature-flag-rollout prompt coverage#853
cursor[bot] wants to merge 1 commit into
mainfrom
cursor/missing-test-coverage-cb6c

Conversation

@cursor

@cursor cursor Bot commented Aug 22, 2026

Copy link
Copy Markdown
Contributor

Description

Adds targeted regression tests for recently merged FME native-mode work and MCPB release metadata validation.

Risky behavior now covered

  • flattenTrafficType / fmeListExtract / fmeGetExtract — FME feature-flag responses nest trafficType.id; flattening to trafficTypeId is required for openInHarness deep links (/targets/{trafficTypeId}/splits/{id}). A regression here silently breaks Harness UI links on list/get.
  • fmeV4PaginatedListExtract — Native v4 list APIs return { data, totalCount }; the extractor promotes these to { items, total } so harness_list pagination stays correct. Tests cover the happy path and non-array passthrough.
  • feature-flag-rollout prompt — Recent commits (feat: wire native FME feature flag definition list, delete, and execute #831, feat: wire native FME traffic type and rollout status lists #838) removed stale native-mode caveats after fme_rollout_status and flag-definition execute actions were wired. Prompt tests lock in correct scope args and guard against reintroducing "not yet implemented" warnings.
  • MCPB release metadataassetNameForVersion and normalizeBundleManifest now reject invalid versions and manifest/package mismatches (Publish versioned MCPB release assets #846).

Test files added/updated

  • tests/registry/fme-extractors.test.ts (new)
  • tests/prompts/feature-flag-rollout.test.ts (new)
  • tests/release-metadata.test.ts (updated)

Why these tests materially reduce regression risk

FME dual-mode migration (#806#838) touched shared extractors and prompt guidance that agents rely on for rollout workflows. The extractors had dispatch-level pagination tests but no unit coverage for trafficTypeId flattening or deep-link URL construction — the highest-impact gap for user-facing links. Prompt tests prevent stale caveats from misleading agents after native APIs land.

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Other (test coverage)

Checklist

  • pnpm test passes (targeted: 28 tests in 3 files)
  • pnpm typecheck passes
  • pnpm build passes
  • pnpm standards:check passes
  • pnpm docs:check passes (registry/tool counts unchanged)
Open in Web View Automation 

Cover flattenTrafficType, fmeV4PaginatedListExtract, and deep-link
trafficTypeId projection added in recent FME native-mode work (#806,
#831, #838). Add prompt tests to guard against stale native-mode
caveats after fme_rollout_status was wired. Harden MCPB release metadata
validation edge cases from #846.

Co-authored-by: Rohan Gupta <thisrohangupta@users.noreply.github.com>
@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

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.

2 participants