Skip to content

testing: 13 of 17 hook files have zero unit test coverage #295

Description

@Austinaminu2

Problem

Of 17 files in `hooks/`, only 4 have tests in `tests/hooks/`: `use-batch-create`, `use-now`, `use-token-verification`, `use-streams`. No tests exist for `use-contract.ts`, `use-wallet.ts`, `use-auto-withdraw.ts`, `use-webhooks.ts`, `use-notifications.ts`, `use-token-price.ts`, `use-activity-feed.ts`, `use-form-draft.ts`, `use-stream-history.ts`, `use-show-usd.ts`, `useBulkActions.ts`, `useBulkSelect.ts`, `useNotifications.ts`.

Location

`hooks/.ts` vs `tests/hooks/`

Impact

Several bugs found in this audit (stale closures, race conditions, effect-dependency issues) live in exactly these untested files — absence of tests correlates directly with where real bugs were found.

Suggested fix

Prioritize tests for hooks tied to money movement first: `use-contract.ts`, `use-auto-withdraw.ts`, `use-wallet.ts`. Track progress against coverage thresholds (see companion issue).

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programtestingTests and QA

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions