Skip to content

[codex] Fix toolbar column test notification context#1165

Merged
karilint merged 1 commit into
mainfrom
fix/1164-toolbar-test-notification-provider
May 22, 2026
Merged

[codex] Fix toolbar column test notification context#1165
karilint merged 1 commit into
mainfrom
fix/1164-toolbar-test-notification-provider

Conversation

@karilint
Copy link
Copy Markdown
Collaborator

Summary

  • Wrap TableToolBarColumnButtons test renders in NotificationContextProvider.
  • Keeps TableToolBar on its real useNotify path instead of mocking or weakening production behavior.

Root Cause

TableToolBar now reads notification context through useNotify, but this test harness only provided router and page contexts. Rendering the component in Jest therefore hit a null notification context.

Validation

  • npx jest src/tests/components/TableToolBarColumnButtons.test.tsx --runInBand
  • npm run lint:frontend
  • npm run tsc:frontend
  • commit hook: npm run lint and npm run tsc

Fixes #1164

@karilint karilint mentioned this pull request May 22, 2026
@karilint karilint marked this pull request as ready for review May 22, 2026 07:54
@karilint karilint merged commit 696de21 into main May 22, 2026
4 checks passed
@karilint karilint deleted the fix/1164-toolbar-test-notification-provider branch May 22, 2026 07:54
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.

Unit test fails

1 participant