pnpm install
pnpm run buildRun the test suite:
pnpm test # Watch mode
pnpm run test:run # Single run
pnpm run lint # Dogfood: lint this plugin with itselfTests use fixture files with expected complexity values in comments:
// @complexity myFunction:cyclomatic=3,cognitive=5
function myFunction(x) {
if (x > 0) {
for (const item of items) {
process(item);
}
}
}Add fixtures to tests/fixtures/ organized by file type (e.g., js/, ts/, jsx/, vue/).