Skip to content

feat: emit unified executable test evidence - #1671

Merged
kang-heewon merged 1 commit into
trunkfrom
issue-1487-unified-test-evidence
Aug 1, 2026
Merged

feat: emit unified executable test evidence#1671
kang-heewon merged 1 commit into
trunkfrom
issue-1487-unified-test-evidence

Conversation

@kang-heewon

@kang-heewon kang-heewon commented Aug 1, 2026

Copy link
Copy Markdown
Member

Outcome

@croco/testing now publishes the versioned croco.test-evidence/v1 TypeScript and JSON-schema contract, deterministic JSON/Markdown bundling, strict runtime validation, fidelity enforcement, redaction, and direct-load Vitest and Playwright reporters. Retry-then-pass remains visible as flaky with every supplied attempt, while declared intent stays separate from runtime observations.

Existing verification/provider/failure-drill artifacts can be normalized without losing their source schema. Release profiles may reuse exact-head evidence only when command, profile, provenance, and required artifacts still match. CI forwards the reporter destination, bypasses cached side-effect loss with a dedicated producer when necessary, fails closed on missing native evidence, and publishes one bundle and one summary.

Fixes #1487

Verification

  • pnpm --filter @croco/testing test — 134/134 tests passed on the current head.
  • pnpm --filter @croco/testing typecheck and earlier package lint/build checks passed.
  • Focused evidence, release-spine, CI, manifest, and Turbo contracts — 92/92 tests passed on the current head.
  • Turbo native-producer reproduction — 40/40 tasks executed with 0 cached and emitted 134 Vitest evidence fragments.
  • pnpm public-api:check — 115 package API snapshots matched.
  • pnpm changeset-required:check -- --base origin/trunk --head HEAD — publishable changes covered.
  • pnpm check — 24/25 gates passed, 1 not applicable, 0 failed on the current head.
  • Pre-push workspace gates — 234/234 test tasks and 233/233 typecheck tasks passed on the current head.

Review gates

  • Correctness and regression — PASS. Schema/runtime validation, malformed and missing inputs, deterministic ordering, retry/flaky attempts, mixed-fidelity rejection, reporter loading, collision-safe writing, artifact reuse invalidation, and five-source combined bundles have focused regression coverage.
  • API, security, compatibility, and release — PASS. Public exports and reporter subpaths build declarations, both schemas ship with the package, a minor changeset covers @croco/testing, external inputs reject unknown fields, and structured tokens/private keys plus configured secret samples are redacted and revalidated at the bundle boundary.
  • Maintainability and minimality — PASS. Existing runners and source report schemas remain authoritative; adapters emit small fragments, aggregation is centralized, verification reuses only exact evidence, and CI runs a dedicated producer only when profile execution emitted none.
  • Independent adversarial review — CLEAN. Findings around reporter context, direct loading, structured secrets, mixed fidelity, external validation, deterministic comparison, malformed-output persistence, exact reuse, collision handling, Turbo environment/cache behavior, and test-free profiles were fixed; final re-review approved the native CI gate with 54/54 focused tests.

Residual risk

Only the @croco/testing Vitest suite is guaranteed as the default native CI producer. Application, real-resource, failure-drill, and Playwright integrations use the common adapters/normalizer and combined validation coverage, but individual downstream suites must opt into their fidelity and observation mappers as they adopt the format.

Summary by CodeRabbit

  • 새 기능

    • Vitest와 Playwright 결과를 표준 테스트 증거로 기록하고 재시도·flaky 상태를 보존합니다.
    • JSON·Markdown 번들을 생성하며 누락 아티팩트와 검증 오류를 표시합니다.
    • 민감정보 마스킹, 결정적 직렬화, fidelity 검증을 지원합니다.
    • 검증에 성공한 기존 증거를 재사용할 수 있습니다.
  • 문서

    • 테스트 증거 API, 스키마 및 리포터 사용법을 문서화했습니다.
  • CI 개선

    • 테스트 증거와 검증 결과를 CI 요약 및 아티팩트로 제공합니다.

@coderabbitai

coderabbitai Bot commented Aug 1, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@kang-heewon, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 10 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 15f1ae93-fc33-4020-a036-a70cd2135cbf

📥 Commits

Reviewing files that changed from the base of the PR and between f19a6a4 and 474001a.

⛔ Files ignored due to path filters (1)
  • packages/problems-core/src/generated/problem-code-registry.ts is excluded by !**/generated/**
📒 Files selected for processing (83)
  • .changeset/unified-test-evidence.md
  • .github/workflows/ci.yml
  • docs/problem-code-registry.json
  • package.json
  • packages/docs/src/content/docs/api/problems-core/src/classes/Problem.md
  • packages/docs/src/content/docs/api/problems-core/src/variables/CROCO_PROBLEM_CODE_REGISTRY.md
  • packages/docs/src/content/docs/api/testing/src/classes/CrocoPlaywrightEvidenceReporter.md
  • packages/docs/src/content/docs/api/testing/src/classes/CrocoVitestEvidenceReporter.md
  • packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceContractError.md
  • packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceFidelityError.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertNoTestEvidenceSecrets.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceFidelity.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/classifyTestEvidenceOutcome.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceFileWriter.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestKernelEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/redactTestEvidence.md
  • packages/docs/src/content/docs/api/testing/src/functions/renderTestEvidenceMarkdown.md
  • packages/docs/src/content/docs/api/testing/src/functions/serializeTestEvidence.md
  • packages/docs/src/content/docs/api/testing/src/functions/testEvidenceFidelityFromKernel.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/PlaywrightTestCase.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/PlaywrightTestResult.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceArtifactProbe.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttachment.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttempt.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttemptOutcome.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceDiagnostic.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFidelity.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFidelityRequirement.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFileWriterOptions.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceIntent.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceJsonValue.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceMissingArtifact.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceObservation.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceOutcome.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRecordInput.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReplay.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReporterContext.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReporterOptions.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceResourceStatus.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRunner.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceTiming.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestKernelEvidenceRecordInput.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/VitestTask.md
  • packages/docs/src/content/docs/api/testing/src/variables/TEST_EVIDENCE_SCHEMA_VERSION.md
  • packages/docs/src/content/docs/api/webhooks-core/src/classes/UnknownWebhookEventProblem.md
  • packages/docs/src/content/docs/en/reference/problem-recovery-cookbook.md
  • packages/testing/README.md
  • packages/testing/package.json
  • packages/testing/schemas/test-evidence-bundle-v1.schema.json
  • packages/testing/schemas/test-evidence-v1.schema.json
  • packages/testing/scripts/copy-schemas.mjs
  • packages/testing/src/index.ts
  • packages/testing/src/libs/test-evidence-files.ts
  • packages/testing/src/libs/test-evidence-reporters.ts
  • packages/testing/src/libs/test-evidence.mts
  • packages/testing/src/playwright-reporter.ts
  • packages/testing/src/tests/TestEvidence.spec.ts
  • packages/testing/src/vitest-reporter.ts
  • packages/testing/vitest.config.ts
  • public-api-surface.snapshot.json
  • scripts/problem-registry.mts
  • scripts/public-api-surface.mts
  • scripts/release-gate-maintenance.mts
  • scripts/release-spine-evidence.mts
  • scripts/test-evidence-bundle.mts
  • scripts/test-evidence-runtime.mts
  • scripts/tests/ci-workflow.spec.ts
  • scripts/tests/problem-registry.spec.ts
  • scripts/tests/public-api-surface.spec.ts
  • scripts/tests/release-spine-evidence.spec.ts
  • scripts/tests/test-evidence-bundle.spec.ts
  • scripts/tests/turbo-task-contract.spec.ts
  • scripts/tests/verification-change-classifier.spec.ts
  • scripts/tests/verification-manifest.spec.ts
  • scripts/verification-manifest.mts
  • scripts/workflow-verification-contract.mts
  • turbo.json
📝 Walkthrough

Walkthrough

테스트 증거 v1 계약과 JSON Schema를 추가했습니다. Vitest·Playwright 리포터가 공통 레코드를 생성합니다. CI는 JSON·Markdown 번들을 만들고, 검증 프로필은 조건에 맞는 증거를 재사용합니다.

Changes

테스트 증거 계약과 핵심 엔진

Layer / File(s) Summary
증거 계약과 스키마
packages/testing/src/libs/test-evidence.mts, packages/testing/schemas/*, packages/testing/src/index.ts
레코드·번들 타입과 JSON Schema를 추가했습니다. fidelity, outcome, attempt, attachment, diagnostic, resource 상태를 정의했습니다.
레코드 검증과 번들 생성
packages/testing/src/libs/test-evidence.mts, packages/testing/src/tests/TestEvidence.spec.ts
flaky 판정, fidelity 검증, redaction, 누락 artifact 처리, 결정적 JSON·Markdown 출력을 추가했습니다.

실행기 리포터와 출력

Layer / File(s) Summary
Vitest·Playwright 리포터
packages/testing/src/libs/test-evidence-reporters.ts, packages/testing/src/vitest-reporter.ts, packages/testing/src/playwright-reporter.ts
Vitest와 Playwright 결과를 공통 레코드로 변환합니다. 재시도, 진단, 실행 시간, 예상 실패, 첨부 파일을 보존합니다.
파일 writer와 Vitest 연결
packages/testing/src/libs/test-evidence-files.ts, packages/testing/vitest.config.ts, packages/testing/src/tests/TestEvidence.spec.ts
환경 변수 기반 출력 경로와 결정적 파일명을 지원합니다. 내용이 다른 기존 파일은 계약 오류로 처리합니다.

번들 및 검증 통합

Layer / File(s) Summary
번들 CLI와 CI 수집
scripts/test-evidence-bundle.mts, .github/workflows/ci.yml, scripts/tests/*, turbo.json
검증 보고서와 증거 입력을 정규화합니다. bundle.jsonsummary.md를 생성하고 누락·무효 입력을 실패 레코드로 기록합니다.
검증 증거 재사용
scripts/release-spine-evidence.mts, scripts/tests/release-spine-evidence.spec.ts
--test-evidence 입력을 검증합니다. 일치하는 커밋, 프로필, 명령, 계약 및 필수 artifact가 있으면 명령을 재실행하지 않습니다.

문서 및 릴리스 지원

Layer / File(s) Summary
공개 API 문서와 릴리스 기록
packages/docs/src/content/docs/api/testing/..., packages/testing/README.md, .changeset/unified-test-evidence.md
새 타입, 함수, 오류 클래스, 리포터 API와 실행형 테스트 증거 사용법을 문서화했습니다. minor 릴리스 changeset을 추가했습니다.
공개 표면과 문서 형식 갱신
public-api-surface.snapshot.json, packages/docs/src/content/docs/api/...
테스트 증거 export와 Schema asset 경로를 공개 표면에 반영했습니다. 기존 API 문서 형식을 갱신했습니다.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant TestRunner
  participant EvidenceReporter
  participant EvidenceWriter
  participant BundleCLI
  participant Verification
  TestRunner->>EvidenceReporter: 테스트 결과와 시도 전달
  EvidenceReporter->>EvidenceWriter: TestEvidenceRecord 기록
  EvidenceWriter->>BundleCLI: JSON 레코드 제공
  BundleCLI->>BundleCLI: 레코드 검증 및 bundle.json 생성
  BundleCLI->>Verification: 검증 증거 번들 제공
  Verification->>Verification: 일치하는 artifact와 명령 확인
Loading

Possibly related issues

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning 대부분의 변경은 테스트 증거 목표와 관련되지만, UnknownWebhookEventProblem.md의 표기 정리와 같은 무관한 문서 변경이 포함되었습니다. UnknownWebhookEventProblem.md의 무관한 표기 변경을 별도 PR로 이동하거나 제거하십시오.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed 제목은 Vitest·Playwright·CI를 포함한 통합 실행 테스트 증거 발행이라는 PR의 주요 변경을 간결하게 설명합니다.
Linked Issues check ✅ Passed 버전 스키마, 두 리포터, flaky 시도 보존, fidelity 검증, redaction, 결정적 번들, artifact 누락 처리, 증거 재사용 요구를 구현했습니다 [#1487].
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch issue-1487-unified-test-evidence

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Aug 1, 2026

Copy link
Copy Markdown

📊 Benchmark Results

✅ All benchmarks passed

Benchmark p75 Threshold Baseline vs Baseline Status Notes
CrocoApp constructor 44.2μs 30.0ms 8.2μs +440.1% -
CrocoApp lambdaHandler (10 controllers) 2.5ms 50.0ms 258.4μs +874.5% -
Lambda cold-start simulation 2.0ms 80.0ms 418.1μs +371.6% -
Lambda cold-start with headers 1.8ms 80.0ms 369.7μs +379.9% -
Lambda cold-start with binary body 1.5ms 80.0ms 339.1μs +354.2% -
Lambda cold-start with query params 1.5ms 80.0ms 301.3μs +411.6% -
Lambda cold-start with authorizer context 1.5ms 80.0ms 299.8μs +401.3% -
Lambda cold-start realistic scenario 1.5ms 80.0ms 299.2μs +396.0% -
EventBusConfig.start (10 handlers) 1.7μs 10.0ms 1.4μs +17.5% -
EventPublisher.publishNow single event 1.9μs 2.0ms 1.7μs +13.7% -
DefaultHandlerResolver.resolve × 10 0.1μs 5.0ms 0.1μs -11.2% -
Container.get singleton (cold) 96.6μs 5.0ms 70.3μs +37.5% -
Container.register × 50 components 3.1ms 10.0ms 3.2ms -4.3% -
Container.validate (50 components) 3.8ms 20.0ms 3.4ms +11.4% -
Container.get singleton (warm) 1.7μs 500.0μs 1.6μs +1.2% -
TelemetryRuntime.init (lambda preset) 2.3μs 200.0ms 1.1ms -99.8% -
lambdaPreset config creation 1.5μs 2.0ms 1.4μs +6.4% -

Updated: 2026-08-01T22:44:43.897Z · Commit: 504db68

@kang-heewon
kang-heewon force-pushed the issue-1487-unified-test-evidence branch 3 times, most recently from c6208ed to 31f91c2 Compare August 1, 2026 17:13

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 20

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
scripts/verification-manifest.mts (1)

547-557: 🚀 Performance & Scalability | 🟠 Major | 🏗️ Heavy lift

--force는 모든 실행에서 test 태스크 캐시를 무효화합니다.

--force는 영향 범위 내 모든 test 태스크를 항상 다시 실행합니다. test는 이 매니페스트에서 가장 긴 태스크입니다(timeout 45분). 따라서 CI와 로컬 검증의 캐시 재사용이 완전히 사라지고, 저장소의 ci-performance-budget 게이트에도 부담이 갑니다.

근본 원인은 turbo.jsonCROCO_TEST_EVIDENCE_DIRglobalPassThroughEnv에 넣은 점입니다. passthrough 환경 변수는 태스크 해시에 포함되지 않으므로, 캐시 적중 시 증거 파일이 생성되지 않습니다. 다음 중 하나를 사용하면 캐시를 유지하면서 증거를 보장할 수 있습니다.

  • test 태스크의 envCROCO_TEST_EVIDENCE_DIR를 추가해 해시 입력으로 만듭니다.
  • 증거 파일 경로를 test 태스크의 outputs로 선언해 캐시 복원 시 파일이 복원되게 합니다.

두 방식 모두 .github/workflows/ci.yml Line 203-211의 fallback 단계와 함께 동작합니다.

♻️ 제안 변경
       command: [
         "pnpm",
         "turbo",
         "run",
         "test",
         ...affectedArguments,
-        "--force",
         "--summarize",
         "--continue=always",
       ],

turbo.jsontest 태스크에 해시 입력을 추가합니다.

{
  "tasks": {
    "test": {
      "env": ["CROCO_TEST_EVIDENCE_DIR"]
    }
  }
}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@scripts/verification-manifest.mts` around lines 547 - 557, Remove the
unconditional --force option from the test command in the verification manifest
and update the test task configuration in turbo.json to include
CROCO_TEST_EVIDENCE_DIR as a hashed env input, preserving cache reuse while
ensuring evidence handling remains compatible with the CI fallback.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceContractError.md`:
- Around line 8-16: Update the original TypeScript definition of
TestEvidenceContractError to extend the project’s RFC 7807 Problem base class
instead of Error, and update the writer path that throws this error to use the
Problem subclass. Do not edit the generated Markdown directly; regenerate the
API documentation and validate it with pnpm docs:api:check.

In `@packages/testing/README.md`:
- Around line 130-132: Update the evidence reuse description in the verification
profiles documentation to state that reuse requires exact matches for command,
profile, provenance, observed contract ID, metadata.commitSha, and all required
artifacts. Clarify that records failing any condition are not reused and the
command executes normally.

In `@packages/testing/src/libs/test-evidence-files.ts`:
- Around line 23-38: Update the returned evidence-writer callback around
outputPath and writeFileSync to avoid the existsSync/readFileSync/write race
when multiple processes share the directory: write serialized content to a
unique temporary file, then atomically publish it with renameSync while
preserving collision detection and throwing TestEvidenceContractError when
existing content differs. Verify the CI configuration uses a shared
CROCO_TEST_EVIDENCE_DIR so the implementation covers parallel package writers.

In `@packages/testing/src/libs/test-evidence-reporters.ts`:
- Around line 1-12: Separate the mixed imports in
packages/testing/src/libs/test-evidence-reporters.ts lines 1-12 by keeping
createTestEvidenceRecord in a value import and moving all TestEvidence* symbols
into a separate import type statement; likewise, in
packages/testing/src/libs/test-evidence-files.ts lines 5-9, keep
serializeTestEvidence and TestEvidenceContractError in the value import and move
TestEvidenceRecord into a separate import type statement, preserving the
required external, internal, then relative import ordering.
- Around line 53-67: Update the VitestTask.result and PlaywrightTestResult types
to expose their framework-provided failure fields (Vitest errors and Playwright
error), and use those fields in the default diagnostics paths around the
evidence reporter methods so failed tests include their actual errors. Preserve
custom diagnostics callbacks while giving them a typed context.source that
exposes the same failure information.

In `@packages/testing/src/libs/test-evidence.mts`:
- Around line 252-256: Update the non-record validation branch in the
test-evidence parser to throw a message identifying that the input shape is
invalid, rather than reporting a schemaVersion mismatch. Keep the
schemaVersion-specific message for record inputs whose version is incorrect,
using the existing TestEvidenceContractError and TEST_EVIDENCE_SCHEMA_VERSION
symbols.
- Around line 570-580: Update assertNoTestEvidenceSecrets so JSON.stringify
failures, including BigInt inputs, and non-string results such as undefined are
converted into TestEvidenceContractError rather than causing TypeError. Validate
the serialized result before calling includes, while preserving the existing
secret-sample detection behavior for successfully serialized strings.
- Around line 179-182: Reorder the logic around assertAttempts and
classifyTestEvidenceOutcome so the copied input is sorted by attempt before
validation. Then pass the sorted attempts to assertAttempts, preserving
rejection of missing or duplicate attempt values while accepting valid entries
supplied in any order.
- Around line 847-849: Update escapeMarkdown to escape pipe characters,
newlines, and backticks so multiline record IDs cannot break Markdown tables or
artifact lists. In the missing-artifact output near recordId/path, apply
escapeMarkdown to both values before interpolation, while preserving existing
formatting.
- Around line 153-171: Update TestEvidenceContractError and
TestEvidenceFidelityError to extend the Problem type from `@croco/problems-core`
instead of Error, while preserving their existing messages and names. Expose
each error’s diagnostic code through the established problemCodes mechanism or
an explicit diagnostic-code property, and associate the codes with the
appropriate problem category.

In `@public-api-surface.snapshot.json`:
- Around line 26130-26151: Update the asset export targets for
test-evidence-bundle-v1 and test-evidence-v1 in public-api-surface.snapshot.json
to use ./dist/schemas/test-evidence-bundle-v1.json and
./dist/schemas/test-evidence-v1.json, matching the files produced by
copy-schemas.mjs; leave the export paths unchanged.
- Around line 24746-24750: Regenerate public-api-surface.snapshot.json using the
standard public API snapshot generation process with the required public API
sources and build outputs available. Ensure the assertNoTestEvidenceSecrets
export from ./libs/test-evidence.mjs receives its inferred declarationKind,
consistent with the inference path in scripts/public-api-surface.mts.

In `@scripts/release-spine-evidence.mts`:
- Line 1054: Update the reuse path around collectArtifactReferences so it does
not pass startedMs = 0 and incorrectly mark all existing artifacts fresh.
Preserve reused artifacts as fresh: false and record the corresponding reuse
record ID in each artifact reference, while leaving normal current-run freshness
detection unchanged.
- Around line 1053-1069: Move the check.reusedEvidence branch in the
report-update flow to execute after the applicable === false branch, preserving
the not_applicable result for checks that are not applicable even when reusable
evidence matches. Remove the now-redundant later applicable === false block only
if the reordered flow retains its behavior, while keeping the reused-artifact
passed path unchanged.
- Around line 1208-1228: Update the test-evidence loading flow around
readFileSync, JSON.parse, and assertTestEvidenceBundle to catch file-read and
JSON-parse failures and convert them into VerificationProblem using the existing
input-error code. Remove the duplicated schema checks, retaining only the
passed-status and empty-missingArtifacts requirements before calling
assertTestEvidenceBundle. Remove the assertTestEvidenceRecord import if it
becomes unused.

In `@scripts/test-evidence-bundle.mts`:
- Around line 157-170: Preserve the original failure details in both
evidence-loading paths. In scripts/test-evidence-bundle.mts lines 157-170, catch
the error in the normalizeTestEvidenceInput flow and pass its message into
inputFailureRecord’s diagnostic. In scripts/release-spine-evidence.mts lines
1208-1228, wrap readFileSync, JSON.parse, and assertTestEvidenceBundle in
try/catch, then throw INVALID_TEST_EVIDENCE_INPUT VerificationProblem including
the underlying error message.
- Around line 157-170: Update the catch block surrounding
normalizeTestEvidenceInput in the test-evidence parsing flow to retain the
caught error and include its diagnostic message in the inputFailureRecord
evidence. Preserve the existing failure code and regeneration guidance while
ensuring both JSON parsing and schema-validation causes are traceable in the
bundle.

In `@scripts/tests/release-spine-evidence.spec.ts`:
- Around line 1016-1027: Split the combined reuseTestEvidence test into two
independent tests: one covering missing required artifacts and another covering
replay command mismatch. Move each setup and assertion into its corresponding
test, and remove the non-null assertion on value.records[0] by accessing the
record safely or restructuring the fixture.
- Around line 928-932: fixture JSON 리터럴에 profile: "spine"을 직접 포함하도록 수정하고, 이후
evidencePath를 다시 읽어 value.records[0]!.metadata.profile을 설정한 뒤 재작성하는 블록을 제거하십시오.
해당 변경으로 non-null assertion과 불필요한 파일 읽기·쓰기를 함께 없애고, fixture가 한 번에 올바른 내용을 생성하도록
유지하십시오.

In `@scripts/tests/test-evidence-bundle.spec.ts`:
- Around line 27-176: normalizeTestEvidenceInput의 미검증 입력 분기를 커버하도록 test evidence
번들 테스트를 확장하십시오. 기존 writeTestEvidenceBundle 테스트에 레코드 배열 입력과
croco.test-evidence/v1 번들 입력 사례를 각각 추가하고, reporter가 생성한 파일이 두 형식 모두 정상적으로 정규화되어
기대한 상태와 레코드로 출력되는지 검증하십시오.

---

Outside diff comments:
In `@scripts/verification-manifest.mts`:
- Around line 547-557: Remove the unconditional --force option from the test
command in the verification manifest and update the test task configuration in
turbo.json to include CROCO_TEST_EVIDENCE_DIR as a hashed env input, preserving
cache reuse while ensuring evidence handling remains compatible with the CI
fallback.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 995c9831-cf15-4a61-a848-bebed33d59e0

📥 Commits

Reviewing files that changed from the base of the PR and between 0e0a46c and 31f91c2.

📒 Files selected for processing (69)
  • .changeset/unified-test-evidence.md
  • .github/workflows/ci.yml
  • package.json
  • packages/docs/src/content/docs/api/testing/src/classes/CrocoPlaywrightEvidenceReporter.md
  • packages/docs/src/content/docs/api/testing/src/classes/CrocoVitestEvidenceReporter.md
  • packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceContractError.md
  • packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceFidelityError.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertNoTestEvidenceSecrets.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceFidelity.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/classifyTestEvidenceOutcome.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceFileWriter.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestKernelEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/redactTestEvidence.md
  • packages/docs/src/content/docs/api/testing/src/functions/renderTestEvidenceMarkdown.md
  • packages/docs/src/content/docs/api/testing/src/functions/serializeTestEvidence.md
  • packages/docs/src/content/docs/api/testing/src/functions/testEvidenceFidelityFromKernel.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceArtifactProbe.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttachment.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttempt.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttemptOutcome.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceDiagnostic.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFidelity.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFidelityRequirement.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFileWriterOptions.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceIntent.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceJsonValue.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceMissingArtifact.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceObservation.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceOutcome.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRecordInput.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReplay.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReporterContext.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReporterOptions.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceResourceStatus.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRunner.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceTiming.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestKernelEvidenceRecordInput.md
  • packages/docs/src/content/docs/api/testing/src/variables/TEST_EVIDENCE_SCHEMA_VERSION.md
  • packages/docs/src/content/docs/api/webhooks-core/src/classes/UnknownWebhookEventProblem.md
  • packages/testing/README.md
  • packages/testing/package.json
  • packages/testing/schemas/test-evidence-bundle-v1.schema.json
  • packages/testing/schemas/test-evidence-v1.schema.json
  • packages/testing/scripts/copy-schemas.mjs
  • packages/testing/src/index.ts
  • packages/testing/src/libs/test-evidence-files.ts
  • packages/testing/src/libs/test-evidence-reporters.ts
  • packages/testing/src/libs/test-evidence.mts
  • packages/testing/src/playwright-reporter.ts
  • packages/testing/src/tests/TestEvidence.spec.ts
  • packages/testing/src/vitest-reporter.ts
  • packages/testing/vitest.config.ts
  • public-api-surface.snapshot.json
  • scripts/release-spine-evidence.mts
  • scripts/test-evidence-bundle.mts
  • scripts/tests/ci-workflow.spec.ts
  • scripts/tests/release-spine-evidence.spec.ts
  • scripts/tests/test-evidence-bundle.spec.ts
  • scripts/tests/turbo-task-contract.spec.ts
  • scripts/tests/verification-manifest.spec.ts
  • scripts/verification-manifest.mts
  • scripts/workflow-verification-contract.mts
  • turbo.json

Comment thread packages/testing/README.md Outdated
Comment thread packages/testing/src/libs/test-evidence-files.ts
Comment thread packages/testing/src/libs/test-evidence-reporters.ts
Comment thread packages/testing/src/libs/test-evidence-reporters.ts Outdated
Comment thread scripts/release-spine-evidence.mts Outdated
Comment thread scripts/test-evidence-bundle.mts
Comment thread scripts/tests/release-spine-evidence.spec.ts Outdated
Comment thread scripts/tests/release-spine-evidence.spec.ts
Comment thread scripts/tests/test-evidence-bundle.spec.ts
@kang-heewon
kang-heewon force-pushed the issue-1487-unified-test-evidence branch 2 times, most recently from f19a6a4 to 17e57b6 Compare August 1, 2026 18:30
Comment thread scripts/release-spine-evidence.mts

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 14

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
scripts/verification-manifest.mts (1)

543-558: 🚀 Performance & Scalability | 🔵 Trivial

--forcetest 작업의 Turbo 캐시 재사용을 항상 비활성화합니다.

--force를 추가하면 spine/publish 프로필에서 test 작업이 캐시 적중 여부와 무관하게 항상 다시 실행됩니다. 이는 Vitest reporter가 실제로 실행되어 신선한 증거를 생성하도록 보장하는 의도된 선택으로 보입니다. 다만 동일 커밋을 재검증하거나 영향받은 패키지가 이미 캐시되어 있는 경우에도 매번 전체 재실행 비용이 발생합니다. CI 실행 시간에 미치는 영향을 관찰하고, 필요하면 캐시된 결과에서 증거 파일만 복원하는 방식도 검토하십시오.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@scripts/verification-manifest.mts` around lines 543 - 558, Update the test
command in the “test” manifest entry to avoid unconditionally passing Turbo’s
“--force” flag, allowing cached test results to be reused; preserve the
summarized-test behavior and ensure cached executions still restore the required
evidence files when supported by the existing verification flow.
♻️ Duplicate comments (1)
packages/testing/src/libs/test-evidence-files.ts (1)

29-39: 🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win

부분 쓰기로 인한 거짓 충돌 오류가 남아 있습니다.

flag: "wx"는 생성 경쟁을 제거합니다. 그러나 writeFileSync는 원자적이지 않습니다. 두 프로세스가 동일한 outputPath를 대상으로 할 때, 두 번째 프로세스는 EEXIST를 받고 Line 33에서 아직 완성되지 않은 파일을 읽을 수 있습니다. 이때 내용이 다르므로 실제 충돌이 없어도 TestEvidenceContractError가 발생합니다. CI가 여러 패키지에서 같은 CROCO_TEST_EVIDENCE_DIR를 공유하면 증거 수집이 간헐적으로 실패합니다.

임시 파일에 쓴 뒤 renameSync로 게시하십시오. 이 방식은 게시를 원자적으로 만들고 충돌 검사도 완성된 내용만 비교합니다.

🔒️ 제안된 수정
-import { mkdirSync, readFileSync, writeFileSync } from "node:fs";
+import { mkdirSync, readFileSync, renameSync, rmSync, writeFileSync } from "node:fs";
     const serialized = serializeTestEvidence(record);
+    const temporaryPath = `${outputPath}.${process.pid}.tmp`;
     try {
-      writeFileSync(outputPath, serialized, { flag: "wx" });
+      writeFileSync(temporaryPath, serialized);
+      renameSync(temporaryPath, outputPath);
     } catch (error) {
+      rmSync(temporaryPath, { force: true });
       if (!isAlreadyExistsError(error)) throw error;

renameSync는 기존 파일을 덮어쓰므로, 충돌 검사를 유지하려면 rename 전에 기존 파일 내용을 비교하는 순서로 재구성하십시오.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/testing/src/libs/test-evidence-files.ts` around lines 29 - 39,
Update the evidence write flow around writeFileSync and the existing EEXIST
handling to write serialized content to a unique temporary file first, then
compare any existing outputPath before publishing with renameSync. Preserve the
collision error for differing completed content, remove the temporary file on
failed or redundant publication, and ensure rename does not overwrite an
existing file.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/testing/package.json`:
- Around line 29-37: Update the package exports for ./playwright-reporter and
./vitest-reporter so the types condition precedes import and require, mapping
each module condition to its corresponding declaration file format, d.mts for
ESM and d.cts for CJS. Update the tsup configuration at the referenced build
setup to emit both declaration files and ensure the exports point to them.

In `@packages/testing/schemas/test-evidence-bundle-v1.schema.json`:
- Line 25: Update the $id values in
packages/testing/schemas/test-evidence-bundle-v1.schema.json:25-25 and
packages/testing/schemas/test-evidence-v1.schema.json:3-3 so each ends with its
exact schema filename, preserving the relative $ref resolution. In
packages/testing/src/tests/TestEvidence.spec.ts:55-71, add assertions verifying
both schemas’ $id final path segments match their respective filenames.

In `@packages/testing/schemas/test-evidence-v1.schema.json`:
- Line 42: Update the attempts schema and its attempt definition to enforce
unique attempt numbers where supported, and add a description documenting that
values must be consecutive starting at 1. Keep the existing minimum constraint
and runtime validation behavior aligned with this documented contract.

In `@packages/testing/src/libs/test-evidence-reporters.ts`:
- Around line 214-226: Update the default attempts mapping in the test evidence
reporter to sort results by PlaywrightTestResult.retry before mapping them, and
derive each attempt number from retry (retry + 1) instead of the array index.
Keep the existing attachment, duration, and outcome handling unchanged, and
leave the custom this.options.attempts callback behavior intact.
- Around line 195-211: In the diagnostics construction around the test result
handling, define the failed-result predicate once and reuse it for both error
collection and the failure flag passed to failureDiagnostics. Update the filter
and some calls to reference that shared predicate so diagnostics selection and
failure detection cannot diverge.

In `@packages/testing/src/libs/test-evidence.mts`:
- Around line 397-416: Update the missingArtifacts validation around
bundle.missingArtifacts.forEach to verify each artifact.recordId exists in the
bundle’s records ID set before accepting it. Reject unknown recordId values with
TestEvidenceContractError, while preserving the existing non-empty and required
checks.
- Around line 182-189: Update createTestEvidenceRecord to validate that
input.intent, input.replay, and input.attempts is an array before dereferencing
or spreading them, and raise the established Problem type with stable diagnostic
codes for invalid shapes. Perform these guards before sorting attempts, while
preserving the existing validation flow for valid input.
- Around line 433-441: Extract the shared status derivation used by the
validation block and createTestEvidenceBundle into a single helper, analogous to
summarizeRecords. Update both callers to use this helper while preserving the
existing failed-versus-passed rules based on failed, flaky, and missing-artifact
counts.

In `@packages/testing/src/tests/TestEvidence.spec.ts`:
- Around line 244-256: In the test case “redacts structured tokens and private
keys from ordinary string fields,” add a concise comment next to the
AKIAIOSFODNN7EXAMPLE fixture stating that it is an intentional AWS documentation
example, not a real credential, so static scanners and reviewers recognize the
expected test value.
- Around line 55-71: 보이는 스키마 동기화 테스트에 각 스키마의 $id를 검증하는 단정을 추가하십시오.
test-evidence-v1 스키마와 test-evidence-bundle-v1 스키마의 $id 마지막 경로 세그먼트가 각각 해당 JSON
파일명과 일치하는지 확인하고, 기존 schemaVersion 및 $ref 검증은 유지하십시오.

In `@scripts/release-spine-evidence.mts`:
- Around line 1083-1103: Fallback execution must clear reused-evidence metadata
when required artifacts are missing. In the fallback path following the failed
collectReusedArtifactReferences check, update the result derived from
report.checks[index] so reusedEvidence is explicitly undefined or omitted before
the rerun update at updateCheck, while preserving reuse metadata for the
successful reuse path. Add a test covering missing required artifacts and verify
the final report does not mark the rerun as reused.

In `@scripts/test-evidence-bundle.mts`:
- Around line 212-236: Update parseArguments to replace its generic TypeError
throws for missing --input, missing --output, unknown arguments, and missing
required input paths with the established Problem subclass and Problem code
pattern used by release-spine-evidence. Preserve the existing validation
conditions and messages while ensuring each CLI parsing failure exposes the
appropriate Problem code.
- Around line 91-138: Update the evidence flow across
EvidenceCommand/EvidenceCheckResult, verification-manifest check definitions,
and ReleaseEvidenceCheck to carry each check’s actual fidelity. In the record
construction within test-evidence-bundle, replace the hardcoded fidelity values
with the propagated or category/check-ID mapping, preserving isolated fidelity
for typecheck/public-api and resource-backed fidelity for CORE_COVERAGE or
test:real checks.

In `@scripts/tests/public-api-surface.spec.ts`:
- Around line 113-136: Extend the test covering getCodeEntrypoint and
resolveLocalModule to also verify a .cjs re-export resolves to the corresponding
.cts source declaration. Add a separate .cjs/.cts case or parameterize the
existing .mjs/.mts case, preserving the current assertions for declarationKind,
name, and source.

---

Outside diff comments:
In `@scripts/verification-manifest.mts`:
- Around line 543-558: Update the test command in the “test” manifest entry to
avoid unconditionally passing Turbo’s “--force” flag, allowing cached test
results to be reused; preserve the summarized-test behavior and ensure cached
executions still restore the required evidence files when supported by the
existing verification flow.

---

Duplicate comments:
In `@packages/testing/src/libs/test-evidence-files.ts`:
- Around line 29-39: Update the evidence write flow around writeFileSync and the
existing EEXIST handling to write serialized content to a unique temporary file
first, then compare any existing outputPath before publishing with renameSync.
Preserve the collision error for differing completed content, remove the
temporary file on failed or redundant publication, and ensure rename does not
overwrite an existing file.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 045c54c2-6bde-4830-bcd4-65af7cc2a1f9

📥 Commits

Reviewing files that changed from the base of the PR and between 31f91c2 and f19a6a4.

📒 Files selected for processing (76)
  • .changeset/unified-test-evidence.md
  • .github/workflows/ci.yml
  • package.json
  • packages/docs/src/content/docs/api/problems-core/src/classes/Problem.md
  • packages/docs/src/content/docs/api/problems-core/src/variables/CROCO_PROBLEM_CODE_REGISTRY.md
  • packages/docs/src/content/docs/api/testing/src/classes/CrocoPlaywrightEvidenceReporter.md
  • packages/docs/src/content/docs/api/testing/src/classes/CrocoVitestEvidenceReporter.md
  • packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceContractError.md
  • packages/docs/src/content/docs/api/testing/src/classes/TestEvidenceFidelityError.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertNoTestEvidenceSecrets.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceFidelity.md
  • packages/docs/src/content/docs/api/testing/src/functions/assertTestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/classifyTestEvidenceOutcome.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceFileWriter.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/createTestKernelEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/functions/redactTestEvidence.md
  • packages/docs/src/content/docs/api/testing/src/functions/renderTestEvidenceMarkdown.md
  • packages/docs/src/content/docs/api/testing/src/functions/serializeTestEvidence.md
  • packages/docs/src/content/docs/api/testing/src/functions/testEvidenceFidelityFromKernel.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/PlaywrightTestCase.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/PlaywrightTestResult.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceArtifactProbe.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttachment.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttempt.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceAttemptOutcome.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceBundle.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceDiagnostic.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFidelity.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFidelityRequirement.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceFileWriterOptions.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceIntent.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceJsonValue.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceMissingArtifact.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceObservation.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceOutcome.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRecord.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRecordInput.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReplay.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReporterContext.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceReporterOptions.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceResourceStatus.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceRunner.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestEvidenceTiming.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/TestKernelEvidenceRecordInput.md
  • packages/docs/src/content/docs/api/testing/src/type-aliases/VitestTask.md
  • packages/docs/src/content/docs/api/testing/src/variables/TEST_EVIDENCE_SCHEMA_VERSION.md
  • packages/docs/src/content/docs/api/webhooks-core/src/classes/UnknownWebhookEventProblem.md
  • packages/testing/README.md
  • packages/testing/package.json
  • packages/testing/schemas/test-evidence-bundle-v1.schema.json
  • packages/testing/schemas/test-evidence-v1.schema.json
  • packages/testing/scripts/copy-schemas.mjs
  • packages/testing/src/index.ts
  • packages/testing/src/libs/test-evidence-files.ts
  • packages/testing/src/libs/test-evidence-reporters.ts
  • packages/testing/src/libs/test-evidence.mts
  • packages/testing/src/playwright-reporter.ts
  • packages/testing/src/tests/TestEvidence.spec.ts
  • packages/testing/src/vitest-reporter.ts
  • packages/testing/vitest.config.ts
  • public-api-surface.snapshot.json
  • scripts/public-api-surface.mts
  • scripts/release-spine-evidence.mts
  • scripts/test-evidence-bundle.mts
  • scripts/tests/ci-workflow.spec.ts
  • scripts/tests/public-api-surface.spec.ts
  • scripts/tests/release-spine-evidence.spec.ts
  • scripts/tests/test-evidence-bundle.spec.ts
  • scripts/tests/turbo-task-contract.spec.ts
  • scripts/tests/verification-manifest.spec.ts
  • scripts/verification-manifest.mts
  • scripts/workflow-verification-contract.mts
  • turbo.json

Comment thread packages/testing/package.json Outdated
Comment thread packages/testing/schemas/test-evidence-bundle-v1.schema.json
Comment thread packages/testing/schemas/test-evidence-v1.schema.json
Comment thread packages/testing/src/libs/test-evidence-reporters.ts
Comment thread packages/testing/src/libs/test-evidence-reporters.ts
Comment thread packages/testing/src/tests/TestEvidence.spec.ts
Comment thread scripts/release-spine-evidence.mts
Comment thread scripts/test-evidence-bundle.mts
Comment thread scripts/test-evidence-bundle.mts Outdated
Comment thread scripts/tests/public-api-surface.spec.ts Outdated
@kang-heewon

Copy link
Copy Markdown
Member Author

CodeRabbit outside-diff finding follow-up:

The unconditional --force is intentional and retained. CROCO_TEST_EVIDENCE_DIR points to a shared CI directory outside each Turbo task output. Adding it as a hashed env input only changes cache keys; it does not recreate native per-run evidence on a cache hit. Declaring the shared global directory as every package test task output would also create overlapping output ownership and unsafe cache restoration.

The verification profile therefore forces affected test execution so the evidence describes the current invocation, while the CI fallback remains only for unsupported reporters. This path passed the repository performance budget, full 234/234 pre-push tests, and the independent adversarial review.

@kang-heewon
kang-heewon force-pushed the issue-1487-unified-test-evidence branch from 17e57b6 to 7cbbc6d Compare August 1, 2026 19:32
@kang-heewon
kang-heewon force-pushed the issue-1487-unified-test-evidence branch 3 times, most recently from b352683 to 8b41e6e Compare August 1, 2026 21:52
@kang-heewon
kang-heewon force-pushed the issue-1487-unified-test-evidence branch from 8b41e6e to 474001a Compare August 1, 2026 22:19
@kang-heewon
kang-heewon merged commit abb5e10 into trunk Aug 1, 2026
12 of 13 checks passed
@kang-heewon
kang-heewon deleted the issue-1487-unified-test-evidence branch August 1, 2026 23:12
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.

[testing] Emit unified executable test evidence across runners

1 participant