Commit ecdda49
authored
feat(event-router): E2E integration tests for event-triggered saga dispatch (#1377)
* feat(event-router): add E2E integration tests for event-triggered saga dispatch
Add comprehensive integration tests verifying the full event-to-saga
dispatch flow using testcontainers (CockroachDB + Kafka). Tests cover:
- Happy path: event matching CEL filter triggers correct saga
- Filter rejection: non-matching events silently skipped
- Metadata filtering: CEL filters on metadata fields
- Idempotency: duplicate events with same correlation ID deduplicated
- Chain depth enforcement: events exceeding max depth dropped
- Multi-saga dispatch: multiple sagas on same channel with different filters
- E2E Kafka: publish to Kafka topic, consume, evaluate filters, trigger sagas
* fix: address PR review comments for integration tests
- Log errors in consumeAndDispatch instead of silently discarding them
- Add explanatory comment for the idempotency wait-then-timeout pattern
---------
Co-authored-by: Ben Coombs <bjcoombs@users.noreply.github.com>1 parent e5ea18c commit ecdda49
2 files changed
Lines changed: 978 additions & 0 deletions
0 commit comments