Skip to content

Commit 01b2d49

Browse files
committed
refactor: improve search tests, stories, and docs
- Add unit tests for all 4 search providers (38 tests) - Remove unused SearchCategory types (orders, workshops, volunteers) - Refactor Storybook stories with reusable SearchModalShell/ResultsList - Add Loading and PagesOnly story variants - Update docs to reflect current implementation
1 parent c416340 commit 01b2d49

4 files changed

Lines changed: 221 additions & 179 deletions

File tree

docs/ENHANCED_SEARCH_IMPLEMENTATION.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -123,11 +123,11 @@ Ready to implement when needed (documented in README):
123123

124124
## Testing & Quality
125125

126-
- **ESLint**: No linting errors
127-
- **TypeScript**: Full type safety
128-
- **Storybook**: Stories updated (builds successfully)
129-
- **Code Review**: All feedback addressed
130-
- **Security**: CodeQL scan - 0 vulnerabilities found
126+
- **Unit Tests**: All 4 search providers have comprehensive test suites (`__tests__/lib/search/`)
127+
- **Storybook**: Stories cover empty, results, loading, no-results, error, and single-category states
128+
- **ESLint**: No linting errors
129+
- **TypeScript**: Full type safety
130+
- **Knip**: No unused exports
131131

132132
## Files Changed
133133

@@ -141,7 +141,11 @@ Ready to implement when needed (documented in README):
141141
- `src/lib/search/providers/index.ts` - Provider exports
142142
- `src/lib/search/hooks/useUnifiedSearch.ts` - Unified search hook
143143
- `src/lib/search/index.ts` - Module exports
144-
- `src/lib/search/README.md` - Comprehensive documentation
144+
- `src/lib/search/README.md` - Architecture documentation
145+
- `__tests__/lib/search/AdminPagesSearchProvider.test.ts` - Admin pages tests
146+
- `__tests__/lib/search/ProposalsSearchProvider.test.ts` - Proposals tests
147+
- `__tests__/lib/search/SponsorsSearchProvider.test.ts` - Sponsors tests
148+
- `__tests__/lib/search/SpeakersSearchProvider.test.ts` - Speakers tests
145149

146150
### Modified
147151

0 commit comments

Comments
 (0)