Skip to content

test(map): track symbol-aware fixture index#101

Merged
PatrickSys merged 2 commits intomasterfrom
fix/codebase-map-baseline
Apr 14, 2026
Merged

test(map): track symbol-aware fixture index#101
PatrickSys merged 2 commits intomasterfrom
fix/codebase-map-baseline

Conversation

@PatrickSys
Copy link
Copy Markdown
Owner

Summary

This restores the tracked fixture data that tests/codebase-map.test.ts expects for symbol-aware keyInterfaces coverage.

What changed

  • add tests/fixtures/map-fixture/.codebase-context/index.json
  • add a narrow .gitignore exception so this fixture artifact stays tracked in Git

Why

origin/master was red because the fixture index was only present locally and ignored by Git, so CI never saw the symbol-aware chunks that back the keyInterfaces assertions and markdown snapshot.

Verification

  • pnpm test -- tests/codebase-map.test.ts
  • pnpm run type-check

The full local suite on this worktree still shows unrelated baseline timeouts/build prerequisites outside this fix; this PR is intentionally limited to the concrete GitHub failure it repairs.

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Apr 14, 2026

Greptile Summary

This PR fixes a CI failure by committing the previously gitignored tests/fixtures/map-fixture/.codebase-context/index.json fixture and adding a narrow .gitignore negation so it stays tracked. The two P2 findings (a buildId that suggests iterative generation and a minor endLine discrepancy on chunk c2) are non-blocking.

Confidence Score: 5/5

  • Safe to merge — the change is a minimal fixture commit and gitignore fix with only P2 findings.
  • All findings are P2 (a line-range inconsistency in fixture data and a question about build ID provenance). Neither blocks correctness or introduces a defect on the changed path.
  • tests/fixtures/map-fixture/.codebase-context/index.json — verify endLine for chunk c2 and confirm the fixture was pre-designed.

Important Files Changed

Filename Overview
tests/fixtures/map-fixture/.codebase-context/index.json Adds a four-chunk symbol-aware index fixture backing the keyInterfaces tests. Minor inconsistency: chunk c2 declares endLine: 20 but its content is only 6 lines (ending at line ~15). The buildId: "test-build-13" warrants a clarification that this was pre-designed rather than retroactively tuned to pass tests per AGENTS.md Evaluation Integrity rules.
.gitignore Adds a targeted negation exception !tests/fixtures/map-fixture/.codebase-context/index.json after the broad **/.codebase-context/* exclusion. Pattern ordering is correct and the directory itself is not excluded, so the negation will take effect as expected.

Sequence Diagram

sequenceDiagram
    participant CI as CI Runner
    participant Git as Git / .gitignore
    participant Test as codebase-map.test.ts
    participant Fixture as map-fixture/.codebase-context/index.json
    participant Builder as buildCodebaseMap()

    CI->>Git: checkout repo
    Git-->>CI: index.json now tracked (negation exception added)
    CI->>Test: pnpm test
    Test->>Builder: createProjectState(FIXTURE_ROOT)
    Builder->>Fixture: read index.json
    Fixture-->>Builder: 4 chunks (3 symbolAware)
    Builder-->>Test: "CodebaseMapSummary { keyInterfaces: [...] }"
    Test->>Test: "assert keyInterfaces[0].name === 'SearchOptions'"
    Test->>Test: assert signatureHint, kind, file, importerCount
    Test-->>CI: ✅ pass
Loading

Reviews (1): Last reviewed commit: "test(map): track symbol-aware fixture in..." | Re-trigger Greptile

Comment thread tests/fixtures/map-fixture/.codebase-context/index.json Outdated
Comment thread tests/fixtures/map-fixture/.codebase-context/index.json Outdated
@PatrickSys
Copy link
Copy Markdown
Owner Author

Follow-up on the Greptile review: commit 6aab54c fixes the c2 metadata mismatch by aligning �ndLine with the embedded synthetic fixture content, and replaces the misleading est-build-13 label with the stable fixture identifier map-fixture-v1. This fixture is hand-maintained regression data for codebase-map, not a frozen eval artifact.

@PatrickSys PatrickSys merged commit e8acbfe into master Apr 14, 2026
3 checks passed
@PatrickSys PatrickSys deleted the fix/codebase-map-baseline branch April 14, 2026 19:05
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.

1 participant