CS-10009 Final PR: rename tests/cards → fixtures/realistic, flip default to blank#4837
Conversation
…ult to blank Completes the consolidation started in PRs #4772, #4790, #4798, #4819. - `git mv packages/realm-server/tests/cards packages/realm-server/tests/fixtures/realistic` so the kitchen-sink fixture lives next to `blank/` and `simple/`. - Simplify `fixtureDir()` now that all three fixtures share a single parent directory. - Flip the default fixture in `startPermissionedRealmFixture` and the cache-key canonicalization in `setupPermissionedRealmCached` from `'realistic'` to `'blank'`. Every direct caller already passes an explicit `fixture` or `fileSystem` after the PR 2-4 sweep, so this flip is a no-op for existing tests; it just surfaces the "what does this test actually need?" question for future callers. - Update three comment references that still mentioned `tests/cards/` paths, and point `mise-tasks/services/test-realms`' `node-test_realm` `--path` at the new fixture location. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Host Test Results 1 files ±0 1 suites ±0 1h 40m 47s ⏱️ + 1m 5s Results for commit 0212bc1. ± Comparison against earlier commit 6c023b8. Realm Server Test Results 1 files ±0 1 suites ±0 8m 8s ⏱️ +2s Results for commit 0212bc1. ± Comparison against earlier commit 6c023b8. |
There was a problem hiding this comment.
Pull request overview
This PR completes the realm-server test fixture consolidation by moving the historical kitchen-sink fixture under tests/fixtures/realistic, simplifying fixture resolution, and changing the implicit single-realm fixture default to blank.
Changes:
- Resolves all named fixtures from
tests/fixtures/<name>and flips implicit single-realm setup/cache defaults toblank. - Adds the renamed
realisticfixture contents underpackages/realm-server/tests/fixtures/realistic. - Updates remaining comments and the test-realms service path to the new realistic fixture location.
Reviewed changes
Copilot reviewed 5 out of 60 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
packages/realm-server/tests/helpers/index.ts |
Simplifies fixture path resolution and changes default fixture/cache canonicalization to blank. |
mise-tasks/services/test-realms |
Points the node test realm service at tests/fixtures/realistic. |
packages/realm-server/tests/server-endpoints/user-and-catalog-test.ts |
Updates fixture path wording in a comment. |
packages/realm-server/tests/server-endpoints/screenshot-card-endpoint-test.ts |
Updates fixture path wording in a comment. |
packages/realm-server/tests/server-endpoints/index-responses-test.ts |
Updates fixture path wording in a comment. |
packages/realm-server/tests/fixtures/realistic/.realm.json |
Adds realistic fixture realm metadata placeholder. |
packages/realm-server/tests/fixtures/realistic/%F0%9F%98%80.gts |
Adds URL-encoded filename fixture module. |
packages/realm-server/tests/fixtures/realistic/a.js |
Adds dependency-chain fixture module. |
packages/realm-server/tests/fixtures/realistic/b.js |
Adds dependency-chain fixture module. |
packages/realm-server/tests/fixtures/realistic/c.js |
Adds dependency-chain fixture module. |
packages/realm-server/tests/fixtures/realistic/card-refs.md |
Adds markdown card-reference fixture content. |
packages/realm-server/tests/fixtures/realistic/chess-gallery.gts |
Adds chess gallery fixture definition. |
packages/realm-server/tests/fixtures/realistic/ChessGallery/2059b2be-791e-47a5-9a9c-be59dee4ea83.json |
Adds chess gallery fixture instance. |
packages/realm-server/tests/fixtures/realistic/ChessGallery/401aa8da-7559-41b5-ae4d-74e455087bd6.json |
Adds chess gallery fixture instance. |
packages/realm-server/tests/fixtures/realistic/ChessGallery/4a46ad31-357f-42fa-8618-0e96f35d1ab9.json |
Adds chess gallery fixture instance. |
packages/realm-server/tests/fixtures/realistic/code-ref-test.gts |
Adds code-ref fixture definition. |
packages/realm-server/tests/fixtures/realistic/cycle-one.js |
Adds cyclic import fixture module. |
packages/realm-server/tests/fixtures/realistic/cycle-two.js |
Adds cyclic import fixture module. |
packages/realm-server/tests/fixtures/realistic/d.js |
Adds dependency/error fixture module. |
packages/realm-server/tests/fixtures/realistic/deadlock/a.js |
Adds deadlock/cycle fixture module. |
packages/realm-server/tests/fixtures/realistic/deadlock/b.js |
Adds deadlock/cycle fixture module. |
packages/realm-server/tests/fixtures/realistic/deadlock/c.js |
Adds deadlock/cycle fixture module. |
packages/realm-server/tests/fixtures/realistic/dir/bar.txt |
Adds directory listing fixture file. |
packages/realm-server/tests/fixtures/realistic/dir/foo.txt |
Adds directory listing fixture file. |
packages/realm-server/tests/fixtures/realistic/dir/subdir/.gitkeep |
Preserves empty directory fixture. |
packages/realm-server/tests/fixtures/realistic/e.js |
Adds intentional-error fixture module. |
packages/realm-server/tests/fixtures/realistic/f.js |
Adds dependency-chain fixture module. |
packages/realm-server/tests/fixtures/realistic/family_photo_card.gts |
Adds family photo fixture definition. |
packages/realm-server/tests/fixtures/realistic/FamilyPhotoCard/265bb8ca-4289-43e2-8a3d-dd1a73c1b024.json |
Adds family photo fixture instance. |
packages/realm-server/tests/fixtures/realistic/FamilyPhotoCard/9be794c4-fb87-4d44-973b-482c4ef0c1c5.json |
Adds family photo fixture instance. |
packages/realm-server/tests/fixtures/realistic/friend.gts |
Adds friend relationship fixture definition. |
packages/realm-server/tests/fixtures/realistic/friend-with-used-link.gts |
Adds used-link relationship fixture definition. |
packages/realm-server/tests/fixtures/realistic/g.js |
Adds dependency-chain fixture module. |
packages/realm-server/tests/fixtures/realistic/hassan-x.json |
Adds remote used-link fixture instance. |
packages/realm-server/tests/fixtures/realistic/hassan.json |
Adds friend fixture instance. |
packages/realm-server/tests/fixtures/realistic/hello.test.gts |
Adds dotted filename resolution fixture module. |
packages/realm-server/tests/fixtures/realistic/home.gts |
Adds home card fixture definition. |
packages/realm-server/tests/fixtures/realistic/index.json |
Adds home card fixture instance. |
packages/realm-server/tests/fixtures/realistic/jade-x.json |
Adds remote used-link fixture instance. |
packages/realm-server/tests/fixtures/realistic/jade.json |
Adds friend fixture instance. |
packages/realm-server/tests/fixtures/realistic/missing-link.json |
Adds broken relationship fixture instance. |
packages/realm-server/tests/fixtures/realistic/multiple-default-exports.gts |
Adds multiple-default-export error fixture module. |
packages/realm-server/tests/fixtures/realistic/multiple-default-exports-card.gts |
Adds card wrapping multiple-default-export fixture. |
packages/realm-server/tests/fixtures/realistic/multiple-default-exports-card.json |
Adds instance for multiple-default-export fixture. |
packages/realm-server/tests/fixtures/realistic/nested/example.js |
Adds nested path fixture module. |
packages/realm-server/tests/fixtures/realistic/person.gts |
Adds person fixture definition. |
packages/realm-server/tests/fixtures/realistic/person.json |
Adds person fixture instance. |
packages/realm-server/tests/fixtures/realistic/person-1.json |
Adds person fixture instance. |
packages/realm-server/tests/fixtures/realistic/person-2.json |
Adds person fixture instance. |
packages/realm-server/tests/fixtures/realistic/person-with-error.gts |
Adds error/search-related person fixture definition. |
packages/realm-server/tests/fixtures/realistic/PersonCard/19c90c40-1df9-42e2-8f85-795229a4bc7c.json |
Adds person-card fixture instance. |
packages/realm-server/tests/fixtures/realistic/PersonCard/50812f7d-fa48-46ed-a45d-548cb254cf48.json |
Adds person-card fixture instance. |
packages/realm-server/tests/fixtures/realistic/PersonCard/936d9784-5e80-4fb5-88e2-8d29a07d07db.json |
Adds person-card fixture instance. |
packages/realm-server/tests/fixtures/realistic/PersonCard/bae37f39-8ee5-4072-a82a-85ef8ec15d6b.json |
Adds person-card fixture instance. |
packages/realm-server/tests/fixtures/realistic/query-test-cards.gts |
Adds query-focused fixture definitions. |
packages/realm-server/tests/fixtures/realistic/realm.json |
Adds RealmConfig fixture instance. |
packages/realm-server/tests/fixtures/realistic/sample.md |
Adds markdown fixture content. |
packages/realm-server/tests/fixtures/realistic/timers-card.gts |
Adds timer error fixture definition. |
packages/realm-server/tests/fixtures/realistic/timers-card.json |
Adds timer card fixture instance. |
packages/realm-server/tests/fixtures/realistic/unused-card.gts |
Adds unused card fixture definition. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- module-cache-race-test.ts third module: pass `fixture: 'blank'` so all three callers in the file are explicit (matches L64 and L315). - screenshot-card-endpoint-test.ts: switch from `realistic` to `blank`. Person/fadhlan does not exist in the realistic fixture and these tests only assert 401/400 status codes, so the cardId never has to resolve. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Summary
Completes the CS-10009 consolidation started in #4772, #4790, #4798, and #4819.
git mv packages/realm-server/tests/cards → packages/realm-server/tests/fixtures/realisticso the kitchen-sink fixture sits next toblank/andsimple/.fixtureDir()now that all three fixtures share a parent directory.startPermissionedRealmFixtureand the cache-key canonicalization insetupPermissionedRealmCachedfrom'realistic'to'blank'. Every direct caller already passes an explicitfixtureorfileSystemafter the PRs 2-4 sweep, so this flip is a no-op for existing tests; it just surfaces the "what does this test actually need?" question for any future caller.tests/cards/paths.mise-tasks/services/test-realmsso thenode-test_realm--pathpoints at the new fixture location (the../host/tests/cardsarm on the next line is the host-side fixture and is out of scope).Closes the implementation plan documented on CS-10009.
Test plan
🤖 Generated with Claude Code