Skip to content

fix: resolve cross-package test failures and type errors - #91

Open
stooit wants to merge 2 commits into
mainfrom
quantcode/e2e-tier3-2418-1785001646
Open

fix: resolve cross-package test failures and type errors#91
stooit wants to merge 2 commits into
mainfrom
quantcode/e2e-tier3-2418-1785001646

Conversation

@stooit

@stooit stooit commented Jul 25, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes all failing tests and type errors across the monorepo. The full suite now passes (13 pass / 0 fail) and tsc --noEmit is clean.

Four cross-package bugs plus a type-config issue were resolved:

  • Renamed hook (apps/web/src/lib/api.ts)useThrottle was renamed to useDebounce in @e2e/utils but the old name was still imported. Restored the useSearchDebounce public export by re-exporting the renamed useDebounce hook.
  • Button accessibility (packages/ui/.../Button.tsx) — icon-only buttons now expose their aria-label as an accessible name (WCAG 4.1.2). Also emits a dev-mode console.warn when an icon-only button is rendered without an aria-label.
  • DataTable stale closure (packages/ui/.../DataTable.tsx) — fixed a stale-closure bug in the re-render handler caught by the controlled re-render test.
  • Date formatting (packages/utils/src/format/date.ts)formatDate now uses the correct day-first locale/format so day 1 is not confused with month 1.
  • Type resolution (tsconfig.json) — resolved the bun:test type resolution error so tsc --noEmit is clean.

Verification

```
bun test packages/utils/test packages/ui/test apps/web/test --preload ./packages/ui/test/setup.ts

13 pass, 0 fail

./node_modules/.bin/tsc --noEmit

exit 0

```

Notes / Assumptions

  • No test files were modified and no dependencies were added, per task constraints.
  • React component tests require the happy-dom preload; without it they fail with a misleading document is not defined.
  • Changes were reviewed by the review subagent; the Button empty-label concern it raised was addressed with the dev warning above.

QuantCode Agent added 2 commits July 25, 2026 17:53
- api: re-export useSearchDebounce from renamed useDebounce hook
- Button: expose aria-label as accessible name on icon-only buttons
- DataTable: fix stale-closure bug in re-render handler
- date: use day-first locale format without leading zero
- tsconfig: resolve bun:test type resolution
Emit a dev console.warn when an icon-only button is rendered without an
aria-label, surfacing the WCAG 4.1.2 accessibility gap to developers.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant