#21027: fix(tests): resolve TypeScript type errors in CLI test files
cli
size: XS
- browser-cli-inspect.test.ts: Cast args to string[] for includes() call to fix TS2345 error when TypeScript infers narrow tuple types
- cron-cli.test.ts: Add missing 'schedule' property to CronUpdatePatch type to fix TS2339 error when accessing patch.schedule in tests
Fixes CI failures in run #22188147945
<!-- greptile_comment -->
<h3>Greptile Summary</h3>
Resolves TypeScript type errors in two CLI test files:
- **`browser-cli-inspect.test.ts`**: Casts `args` to `string[]` to fix TS2345 error. TypeScript inferred `args` as a narrow tuple type from `it.each` test cases, which doesn't have the `includes()` method. The cast resolves this.
- **`cron-cli.test.ts`**: Adds missing `schedule` property to `CronUpdatePatch` type definition to fix TS2339 error. The property is accessed in tests at lines 485-486 and 494 but was missing from the type definition.
Both fixes are straightforward type corrections that align the type definitions with actual runtime usage in the tests.
<h3>Confidence Score: 5/5</h3>
- This PR is safe to merge with minimal risk
- Score reflects simple, well-scoped TypeScript type fixes with no runtime behavior changes. Both changes address real type errors where the type definitions didn't match actual usage in tests.
- No files require special attention
<sub>Last reviewed commit: 694f1da</sub>
<!-- greptile_other_comments_section -->
<sub>(4/5) You can add custom instructions or style guidelines for the agent [here](https://app.greptile.com/review/github)!</sub>
<!-- /greptile_comment -->
Most Similar PRs
#23772: fix(ci): unblock repo-wide check gate type regressions
by SmithLabsLLC · 2026-02-22
79.3%
#23594: test(tui): fix mock typing in command handler tests
by Sashamine · 2026-02-22
79.3%
#21190: test(cron-cli): assert cron.update patch schedule.staggerMs on edit
by ethvilet · 2026-02-19
79.0%
#22990: test: fix readonly typing regressions in CI check baseline
by bmendonca3 · 2026-02-21
77.9%
#20496: test(utils): add comprehensive unit tests for utility functions
by masifislamm · 2026-02-19
77.0%
#17393: fix(ci): resolve TS2742 type error blocking all PRs
by miloudbelarebia · 2026-02-15
76.8%
#7085: test: skip flaky workspace-paths & safe-bins tests on non-Linux/CI ...
by ThinkIbrokeIt · 2026-02-02
76.7%
#4095: Test/add format duration tests
by TechWizard9999 · 2026-01-29
76.3%
#9628: fix: resolve tsconfig rootDir errors by separating UI config (AI-as...
by KGBos · 2026-02-05
76.3%
#22808: test(ui): split baseline browser-test fixes from webchat feature
by opnsec · 2026-02-21
76.1%