← Browse by Chapter
Get the Book →
#69Refactor commit
Here's the function signature: `[paste]`. Here are the constraints I know about: [list domain-specific rules — e.g., "negative prices are invalid, user IDs above 10M are from a legacy migration, the API rejects requests on Sundays"]. Generate additional test cases covering: (1) boundary conditions from the signature, (2) edge cases from the constraints I listed, (3) any boundary conditions you can infer that I haven't listed. For each, explain *why* it's an edge case.

Mastering Claude Code
These prompts are excerpts from the book. Get the full collection with explanations and use cases.