chore(organisation): own the two ingestion tests under source-intake, not app-experience's document-* glob

Merged
BI
1mo ago
+17-0

User description

Summary

  • Two ingestion tests that app-experience's broad tests/document-* glob had claimed now belong to source-intake, the system that owns the code they test:
    • tests/document-extraction-source-fidelity.test.ts exercises src/lib/extractors/** and worker/behavior.ts.
    • tests/document-detail-demo-window.test.ts exercises src/lib/document-detail.ts.
  • Explicit source-intake.json entries take precedence over the glob, so app-experience's tests/search-* and tests/document-* globs stay as they are. No ownership check, gate or budget changed.
  • Of the 73 tests/search-* / tests/document-* tests, 26 already had explicit owners elsewhere. The other 45 that the globs still own test app-experience UI or client code (document viewer, search results, pins, shell, routing) and stay put. No search-* test exercises answer-engine code, so none moved there.
  • Adds a regression test in tests/maintain-docs-system.test.ts that checks the real manifests: the two tests resolve to source-intake, and viewer and search UI tests stay with app-experience.

Areas touched: Knowledge and records

Verification

  • Checks run: all 18 Static PR checks steps locally (check:organisation, check:ci-scope, check:knip, format:changed, check:instructions and the rest), all passing; vitest run tests/maintain-docs-system.test.ts tests/organisation-*.test.ts: 423 passed; npm run verify:pr-local passed every step up to typecheck. The shared box ran out of memory there (exit 137), so I re-ran npm run typecheck on its own, which passed (recorded a pass for "typecheck:internal"). Its remaining full unit test step was left to CI.

Risk and rollout

  • Risk: low. This changes ownership metadata only; no runtime code changed.
  • Rollback: revert the commit.
  • Provider or production effects: None

Notes

  • Left for the owner: tests/document-ingress-safety.test.ts covers ingestion-safety logic, but its subject src/lib/document-ingress-safety.ts is explicitly owned by delivery. Moving only the test would split it from its code, so both should move together if that is wanted.
  • Follow-up to #3610 (built off main after #3614 and #3613 merged).

Summary by cubic

Moves ownership of two ingestion tests from app-experience's broad tests/document-* glob to source-intake, which owns the code they exercise.

  • tests/document-extraction-source-fidelity.test.ts and tests/document-detail-demo-window.test.ts now have explicit entries in source-intake.json, which take precedence over the glob and leave the other 45 glob-owned UI and client tests with app-experience.
  • Adds a regression test in tests/maintain-docs-system.test.ts asserting the real manifests resolve these tests to source-intake and viewer/search UI tests stay with app-experience.
  • No ownership check, gate, or budget changed; no runtime code touched.

CodeAnt-AI Description

Assign ingestion tests to source-intake

What Changed

  • Assign the document extraction and detail tests to source-intake, which owns the code they test.
  • Keep document viewer and search UI tests with app-experience.
  • Add checks to prevent these ownership assignments from drifting.

Impact

โœ… Ingestion tests counted under source-intake
โœ… Viewer and search tests remain with app-experience
โœ… Test ownership changes are checked against the manifests

๐Ÿ’ก Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.