john-okeefe
08b32c7b30
test: add comprehensive tests for unified search endpoint
- Add search_unified_test.go with 8 test cases:
- Fuzzy author filter (asimov → Asimov, Isaac)
- Fuzzy genre filter (scifi → Sci-Fi)
- Exact match with quotes ("Foundation and Empire")
- Combined search + filters (q=foundation&author_filter=asimov)
- Field-specific search for dropdown authors (returns values with counts)
- Year range filter (exact match)
- Boolean filter (has_cover=true)
- Missing library_id validation (400 error)
- Remove filtering_test.go (covered by new tests)
- Uses setupDeviceTest helper following PROJECT_GUIDELINES.md
- Tests both media item search and field value search endpoints
- Validates fuzzy matching, exact matching, and combined queries