Repository navigation
[claude] Test that deleting an entity cascades through referrers - #151
Conversation
Covers the recursive MarkDeleted call in SnapshotWorker: deleting a word deletes its definition via RemoveReference, which must in turn delete the definition's example. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017iyZdteks1z5KpAsAAVMNt
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
WalkthroughAdds a test for recursive deletion. The test checks that deleting a Word marks the referencing Definition and Example as deleted and assigns all three snapshots the delete commit ID. Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~5 minutes Change: Other Merge Risk: ⚪ Minimal · up to
|
[Claude, autonomous]
Adds a
SnapshotWorkerTestscase for the recursiveMarkDeleted(word → definition → example in one delete commit); it fails if the recursion is removed.Closes #97: most of it was already covered when it was filed.
DataModelReferenceTests(DeleteRemovesAllReferencesand the delete/reference block around it) andSnapshotWorkerTests.DeletingAnEntityDropsReferencesToItFromBaselineEntitiescover reference removal. The cascade was only covered byExampleSentenceTests.DeletingAWordDeletesTheExampleSentence, which only asserts that no entity is left undeleted. The loop guard still can't be tested: no sample model has a reference cycle where removing a reference deletes the referrer.Generated by Claude Code