Skip to content

fix: consolidate duplicate indexer integration tests#604

Open
wheval wants to merge 1 commit into
LabsCrypt:mainfrom
wheval:fix/issues-548
Open

fix: consolidate duplicate indexer integration tests#604
wheval wants to merge 1 commit into
LabsCrypt:mainfrom
wheval:fix/issues-548

Conversation

@wheval
Copy link
Copy Markdown
Contributor

@wheval wheval commented Jun 1, 2026

Summary

Consolidates duplicate indexer integration test suites into a single tests/ layout: worker lifecycle tests live in indexer-worker.test.ts, HTTP route tests stay in streams.test.ts, and DB-backed flows remain in stream-lifecycle.test.ts.

Purpose / Motivation

Three overlapping files exercised the same indexer → stream flows (src/__tests__/integration/streams.test.ts, tests/integration/streams.test.ts, and tests/integration/stream-lifecycle.test.ts). The split src/__tests__/ location also duplicated Vitest discovery paths and slowed CI.

Changes Made

  • Moved worker-based indexer tests (including fee_config_updated and admin_transferred) from src/__tests__/integration/streams.test.ts to tests/integration/indexer-worker.test.ts.
  • Removed duplicate POST-based lifecycle blocks from tests/integration/streams.test.ts; that file now covers claimable fallback, SSE contracts, and events pagination only.
  • Deleted backend/src/__tests__/integration/streams.test.ts.
  • Narrowed vitest.config.ts include to tests/** only.

How to Test

  1. From backend/, run the full suite:
    npx vitest run
  2. Run the consolidated integration files:
    npx vitest run tests/integration/indexer-worker.test.ts tests/integration/streams.test.ts tests/integration/stream-lifecycle.test.ts
  3. Expected: all tests pass; no references to src/__tests__/ remain.

Breaking Changes

None.

Related Issues

Closes #548

Checklist

  • Code builds successfully
  • Tests added/updated
  • No console errors
  • Documentation updated (if needed)

Move worker tests to tests/integration/indexer-worker.test.ts,
remove overlapping lifecycle blocks from streams.test.ts, and
drop the src/__tests__ test root.

Closes LabsCrypt#548
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.

[Testing] Consolidate duplicate/overlapping indexer integration test files

1 participant