Skip to content

The agent that grows with you

test(desktop): type the session-timer element props instead of casting unknown

Hermes Agent0e31fd3b45e1
diff --git a/apps/desktop/src/app/shell/hooks/use-statusbar-items.test.tsx b/apps/desktop/src/app/shell/hooks/use-statusbar-items.test.tsx
index 3c3aa027df9..e39e2097ad4 100644
--- a/apps/desktop/src/app/shell/hooks/use-statusbar-items.test.tsx
+++ b/apps/desktop/src/app/shell/hooks/use-statusbar-items.test.tsx
@@ -121,7 +121,7 @@ function sessionTimerItem() {
}
function timerSince(item: ReturnType<typeof sessionTimerItem>): number | null {
- return isValidElement(item?.detail) ? (item.detail.props.since as number | null) : null
+ return isValidElement<{ since: number | null }>(item?.detail) ? item.detail.props.since : null
}
describe('statusbar session timer — focused since (#103123)', () => {