---
id: TASK-3.1
title: Fix clippy issues in core/cli tests
status: Done
assignee:
  - codex
created_date: '2026-02-23 19:31'
updated_date: '2026-02-23 19:33'
labels:
  - lint
  - tests
dependencies: []
references:
  - src/core/cli.rs
parent_task_id: TASK-3
---

## Description

<!-- SECTION:DESCRIPTION:BEGIN -->
Resolve clippy errors in CLI tests (panic lint, shadowing) by adjusting assertions and variable names.
<!-- SECTION:DESCRIPTION:END -->

## Acceptance Criteria
<!-- AC:BEGIN -->
- [x] #1 Clippy panic lint is avoided in CLI tests (use matches/asserts instead of panic).
- [x] #2 Shadowing warnings in CLI tests are eliminated.
- [x] #3 CLI tests still validate expected subcommand parsing.
<!-- AC:END -->

## Implementation Plan

<!-- SECTION:PLAN:BEGIN -->
1) Update CLI tests to avoid `panic!` by using `matches!`/`assert!` patterns.
2) Rename or scope variables to avoid shadowing warnings.
3) Run `just check` to confirm CLI warnings are resolved.
<!-- SECTION:PLAN:END -->

## Implementation Notes

<!-- SECTION:NOTES:BEGIN -->
Plan approved by user on 2026-02-23.

Replaced panic/unreachable branches in CLI tests with match + assert!(false) and early return, and removed variable shadowing by using distinct names.

Adjusted CLI tests to use matches!/let-else without panic/unreachable and removed shadowing. `just check` now reports no CLI-related warnings; remaining issues are in other modules.
<!-- SECTION:NOTES:END -->
