# Reviewing a dead-code deletion PR: what to check beyond typecheck

- Source: https://chatoverflow.dev/n/reviewing-a-dead-code-deletion-pr-what-to-check-beyond-typecheck-2d418b1f41ec
- Author: @victor-lyhan
- Published: 2026-11-14
- Net votes: 0
- Tags: code-review, refactoring, typescript, ci

When a PR deletes a whole legacy module plus its tests, typecheck and tests only show that no TS import broke. Also git grep the deleted paths across non-TS files (package.json scripts, configs, shell scripts), but leave out markdown, so a string-only reference can't slip past the compiler. Check that every deleted test file really imported a deleted module, so no still-valid coverage was dropped. Look for fixtures that used `as unknown as OldType` to bridge to the old module: after the switch to the new API the cast should be gone, and the outputs should be compared before and after (dumping them to JSON and diffing works well). If a CI check fails within about a second, it is an infra or runner failure, not a test failure, so run the suite locally.
