Edge Case Generator
Analyze function signatures and generate boundary value test cases: empty strings, zero, negative numbers, unicode, huge inputs, and more.
Get the CLI Tool
Generate edge case tests locally as an MCP server, or try it online below.
npx @clinetools/edge-cases- Analyzes parameter types to generate type-specific boundary values
- Strings: empty, whitespace, unicode, emoji, very long, SQL injection
- Numbers: 0, -1, MAX_SAFE_INTEGER, NaN, Infinity, floats
- Arrays: empty, single item, duplicates, huge length, nested
- Preference conversation on first run — choose thoroughness level
How to Use It
Three ways to generate edge cases — pick the one that fits your workflow.
Try Online
Paste a function below to get edge case inputs — no install needed.
Use via CLI
Run as a local MCP server. On first run it asks about your thoroughness level.
Add to Cline / Claude Code
Add to your MCP settings so your agent generates edge cases automatically.
MCP Client Configuration
{
"mcpServers": {
"edge-cases": {
"command": "npx",
"args": ["@clinetools/edge-cases"]
}
}
}Try It Online
Paste a function and get boundary value test inputs automatically.
Paste Function Signature
We analyze parameter names and types to generate relevant edge cases
Paste a function and click Generate Edge Cases to get boundary values.
Edge Cases
Why Edge Cases Matter
Most bugs live at the boundaries. Systematic edge case testing finds them before your users do.
The Off-By-One Bug
The most common bug in software. Does your loop handle the last element? Does your slice include the boundary? Edge case testing systematically checks every fence post.
Unicode Chaos
Users type emoji, accented characters, and right-to-left text. Your string functions need to handle \u0000, \uFFFF, surrogate pairs, zero-width joiners, and combining characters.
Number Boundaries
NaN, Infinity, -0, MAX_SAFE_INTEGER+1, floating point precision loss (0.1+0.2). JavaScript numbers are full of traps. Edge case generation covers them all systematically.
Empty Everything
Empty strings, empty arrays, null, undefined, empty objects. What happens when there's nothing? Most crashes come from code that never considered the empty case.
Find Bugs at the Boundaries
Add the Edge Case Generator to your agent's toolkit and test every corner systematically.
View Plans