Skip to content

Conversation

@marevol
Copy link
Contributor

@marevol marevol commented Dec 20, 2025

Summary

  • Add comprehensive integration tests for the public Search API endpoints
  • Enhance existing admin integration tests with additional endpoint coverage
  • Improve test coverage for CSV download/upload, job control, and storage operations

Changes Made

New Search API Integration Tests

  • HealthApiTests: Tests for /api/v1/health endpoint validation
  • LabelsApiTests: Tests for /api/v1/labels endpoint to verify label retrieval
  • PopularWordsApiTests: Tests for /api/v1/popular-words endpoint functionality
  • SuggestWordsApiTests: Tests for /api/v1/suggest-words endpoint with various query parameters
  • FavoritesApiTests: Tests for /api/v1/favorites and document favorite management APIs
  • ScrollSearchApiTests: Tests for /api/v1/documents/all scroll search endpoint (NDJSON format)

Enhanced Admin Integration Tests

  • BadWordTests: Added CSV download and upload endpoint tests
  • ElevateWordTests: Added CSV download and upload endpoint tests
  • SchedulerTests: Added job start and stop endpoint tests
  • StorageTests: Added comprehensive storage CRUD and file operations tests
  • SuggestTests: Added additional suggest management endpoint tests

Testing

Run the integration tests with:

mvn test -P integrationTests -Dtest.fess.url="http://localhost:8080" -Dtest.search_engine.url="http://localhost:9201"

Note: Some tests are marked with @Disabled as they require specific feature configurations:

  • ScrollSearchApiTests: Requires api.search.scroll to be enabled
  • FavoritesApiTests: Requires favorites feature to be enabled and crawled documents

Additional Notes

  • All tests follow the existing test patterns and extend appropriate base classes (ITBase, CrudTestBase, CrawlTestBase)
  • Tests use RestAssured for API testing consistency with the existing test suite
  • Proper cleanup is performed in @AfterAll methods to ensure test isolation

🤖 Generated with Claude Code

Add comprehensive integration tests for the public Search API endpoints:

- HealthApiTests: Tests for /api/v1/health endpoint
- LabelsApiTests: Tests for /api/v1/labels endpoint
- PopularWordsApiTests: Tests for /api/v1/popular-words endpoint
- SuggestWordsApiTests: Tests for /api/v1/suggest-words endpoint
- FavoritesApiTests: Tests for /api/v1/favorites and document favorite APIs
- ScrollSearchApiTests: Tests for /api/v1/documents/all scroll search

Also enhance existing admin integration tests:
- BadWordTests: Add CSV download/upload endpoint tests
- ElevateWordTests: Add CSV download/upload endpoint tests
- SchedulerTests: Add job start/stop endpoint tests
- StorageTests: Add storage CRUD and file operations tests
- SuggestTests: Add additional suggest management tests

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@marevol marevol added this to the 15.4.0 milestone Dec 20, 2025
@marevol marevol added the task label Dec 20, 2025
@marevol marevol self-assigned this Dec 20, 2025
@marevol marevol merged commit 865fe3e into master Dec 20, 2025
1 check passed
@marevol marevol deleted the test/add-search-api-integration-tests branch December 25, 2025 07:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants