mirror of
https://github.com/AgentSeal/codeburn.git
synced 2026-05-19 07:43:09 +00:00
Covers previously untested detectors and helpers with real temp-dir fixtures (not stubs) to verify behavior against actual file I/O. New coverage: - detectMissingClaudeignore: project with/without junk dirs and .claudeignore, impact scaling. - detectBloatedClaudeMd: plain oversized file, @-import expansion, circular import safety, email/npm-scope @-token filtering. - loadMcpConfigs: project reads, colon-to-underscore normalization, malformed JSON tolerance. - detectUnusedMcp: 24-hour grace period, config vs invocation merge. - detectBashBloat: env var unset, configured under/over limit. - detectGhostCommands: path prefixes are not commands, <command-name> tag parsing. - scanJsonlFile: missing file, tool_use parsing, malformed line skipping, date-range filter. - scanAndDetect: empty projects returns healthy result. - estimateContextBudget: system base, MCP tools, memory files. - discoverProjectCwd: empty dir, no jsonl, cwd extraction. Uses vi.mock to redirect os.homedir() to a disposable temp directory, so tests do not read the tester's real ~/.claude. 34 tests, <30ms wall time. Total suite now 160 tests. |
||
|---|---|---|
| .. | ||
| providers | ||
| bash-commands.test.ts | ||
| export.test.ts | ||
| optimize-fs.test.ts | ||
| optimize.test.ts | ||
| provider-registry.test.ts | ||