Commit 32fe8dc
Test User
test(cmd): add comprehensive test coverage for command package
Add test suites achieving >90% coverage for cmd/ package:
- cmd/fmt_test.go: Format command logic, check mode, exit handling
- cmd/lint_test.go: Lint command with all component types
- cmd/root_test.go: Root command flags and execution
- cmd/subcommands_test.go: All subcommand routing
- cmd/summary_test.go: Summary display formatting
Refactor cmd/fmt.go and cmd/root.go to use exitFunc variable for
testability, allowing tests to override os.Exit behavior.1 parent e847ea7 commit 32fe8dc
7 files changed
Lines changed: 4976 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
216 | 216 | | |
217 | 217 | | |
218 | 218 | | |
219 | | - | |
| 219 | + | |
220 | 220 | | |
221 | 221 | | |
222 | 222 | | |
| |||
0 commit comments