code-path-discovery

Scan TypeScript and JavaScript source files to detect behavioral paths in six test categories.

Updated Mar 30, 2026
One-click install
npx skills add https://github.com/rubrical-works/idpf-praxis-skills --skill code-path-discovery-rubrical-works
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: code-path-discovery
Source: https://github.com/rubrical-works/idpf-praxis-skills/tree/main/Skills/code-path-discovery
Command: npx skills add https://github.com/rubrical-works/idpf-praxis-skills --skill code-path-discovery-rubrical-works

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Manually identifying all behavioral paths in a codebase for test planning is slow and error-prone. This Skill automates static analysis of TypeScript/JavaScript code to surface candidate scenarios across nominal, alternative, exception, edge, corner, and negative test categories. ## Core Features & Use Cases - Pattern-Based Scanning: Detects route definitions, conditional branches, error handlers, guard clauses, and validation logic using targeted code patterns. - Six-Category Output: Maps detected patterns to the 6-category path format (nominal, alternative, exception, edge cases, corner cases, negative tests) used by the /paths workflow. - Scope Control: Warns on broad scopes over 50 files and caps processing at 100 files with prioritized ordering. - Use Case: When starting test planning for a new feature, run this against your source directory to get candidate scenarios like "POST /login validates credentials" or "JWT middleware rejects malformed tokens" for collaborative review. ## Quick Start Invoke /paths --from-code with a source directory path and issue title to scan the code and receive categorized behavioral path candidates.

Frequently Asked Questions about code-path-discovery

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I discover test scenarios from existing source code?▼

Run /paths --from-code with a source directory path and issue title. The skill scans TypeScript and JavaScript files for routes, branches, error handlers, and guards, then returns candidate scenarios organized into six test path categories.

What code patterns does static path analysis detect?▼

It detects Express and decorator routes, exported handlers, if/else and switch branches, try-catch blocks, throw statements, null guards, boundary checks, compound conditions, and validation or auth middleware. Each pattern maps to a specific test category.

Which languages does code path scanning support?▼

The skill currently supports TypeScript (.ts, .tsx) and JavaScript (.js, .jsx) files. The detection patterns are regex-based and language-specific, so other languages would require new pattern sets.

What are the limitations of static code path detection?▼

It cannot detect implicit error flows via callbacks, promise chain errors without .catch(), or configuration-driven behavior invisible in code structure. Guard clause detection may also produce false positives on non-boundary conditions.

Why does scanning a large directory produce noisy results?▼

Scanning more than 50 source files triggers a broad scope warning because generic patterns match more irrelevant code. Scope the scan to a specific feature directory, and note the skill caps processing at 100 files.