run test on phase 24 and 33
This commit is contained in:
@@ -85,13 +85,22 @@ public class NotificationPipelineTests : IAsyncLifetime
|
||||
[Fact]
|
||||
public async Task CriticalAlert_Unacknowledged_EscalatesAfterTimeout()
|
||||
{
|
||||
using (var scope = _fixture.Services.CreateScope())
|
||||
{
|
||||
var rabbitOpts = scope.ServiceProvider.GetRequiredService<IOptions<RabbitMqOptions>>();
|
||||
RabbitMqTestHelper.PurgeNotificationQueues(rabbitOpts);
|
||||
await RabbitMqTestHelper.WaitForNotificationPipelineIdleAsync(
|
||||
rabbitOpts, TimeSpan.FromSeconds(90));
|
||||
RabbitMqTestHelper.PurgeNotificationQueues(rabbitOpts);
|
||||
}
|
||||
|
||||
var encounterId = await CreateActiveEncounterAsync();
|
||||
var alertId = await IngestCriticalPotassiumAsync(encounterId);
|
||||
|
||||
// paging worker (≤6s) → DLQ (5s TTL) → escalation worker.
|
||||
// Poll instead of a fixed sleep: earlier tests may leave paging jobs queued
|
||||
// (prefetch=1), so wall-clock time varies across the full integration suite.
|
||||
var deadline = DateTimeOffset.UtcNow.AddSeconds(60);
|
||||
var perAlertCycle = TimeSpan.FromMilliseconds(
|
||||
_fixture.Services.GetRequiredService<IOptions<RabbitMqOptions>>().Value.PagingAckTimeoutMs * 2 + 12_000);
|
||||
var deadline = DateTimeOffset.UtcNow.Add(perAlertCycle);
|
||||
AlertStatus status;
|
||||
do
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user