test(e2e): add batch-size cap coverage for SIENTIAPDE-2013
Also fixes the test_activities fixture, which built mongodb_config by hand and was missing the new required notification_queue_batch_size key -- every e2e test would have hit a KeyError without this. New test seeds 5 notifications with a batch size of 2 and confirms three successive runs return them oldest-first in order (n1,n2 / n3,n4 / n5), proving the cursor only advances to what was actually returned rather than skipping documents a capped query didn't fetch. Verified against real testcontainers Mongo/Redis/Temporal, not mocks. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -110,6 +110,7 @@ No notifications → no SMTP, no Postgres row.
|
||||
- Prior timestamp → only newer notifications returned.
|
||||
- Query-time filter (SIENTIAPDE-2011) → union of active groups' `levels`, intersection of their `ignore_models_id`; a model ignored by only one of several active groups is not excluded from the fetch.
|
||||
- Empty Mongo → no Redis timestamp write.
|
||||
- Batch size cap (SIENTIAPDE-2013) → with 5 pending notifications and a batch size of 2, each run returns exactly the next-oldest 2 (sorted ascending by timestamp), and the Redis cursor advances only to what was actually returned, so three successive runs drain the backlog in order instead of skipping anything.
|
||||
|
||||
### ProcessNotifications — `e2e/test_subworkflow_process_notifications.py`
|
||||
|
||||
|
||||
Reference in New Issue
Block a user