public async Task UnacknowledgedEventWithNonExpiredRetryPolicyIsRetriedAcrossAdditionalStarts() { var @event = new TestDurableEvent(SingleValue); await _bus.PublishDurable(@event); Assume.That(_eventsThatWillBeAcknowledged.ProcessedMessagePayload, Is.EqualTo(SingleValue)); await _bus.Start(); Assert.That(_eventsThatWillBeAcknowledged.ProcessedMessagePayload, Is.EqualTo(string.Format("{0}{0}", SingleValue))); }
public async Task UnacknowledgedEventIsUnaffectedByAcknowledgingOtherSubscriberAcrossAdditionalStarts() { var @event = new TestDurableEvent(SingleValue); await _bus.PublishDurable(@event); Assume.That(_eventsThatWillNotBeAcknowledged.ProcessedMessagePayload, Is.EqualTo(SingleValue)); await _eventsThatWillBeAcknowledged.AcknowledgeLastMessage(_bus); for (int i = 0; i < 10; i++) { await _bus.Start(); } Assert.That(_eventsThatWillBeAcknowledged.ProcessedMessagePayload, Is.EqualTo(SingleValue)); Assert.That(_eventsThatWillNotBeAcknowledged.ProcessedMessagePayload, Is.EqualTo(string.Format("{0}{0}", SingleValue))); }