public void Skip_should_complete_when_all_skipped() { var summary = new InMemoryRetry("abc123", RetryType.FailureGroup); summary.Wait(DateTime.UtcNow); summary.Prepare(1000); summary.PrepareBatch(1000); summary.Skip(1000); Assert.AreEqual(RetryState.Completed, summary.RetryState); Assert.AreEqual(1000, summary.NumberOfMessagesSkipped); }
public void Skip_should_set_update_skipped_messages() { var summary = new InMemoryRetry("abc123", RetryType.FailureGroup); summary.Wait(DateTime.UtcNow); summary.Prepare(2000); summary.PrepareBatch(1000); summary.Skip(1000); Assert.AreEqual(RetryState.Preparing, summary.RetryState); Assert.AreEqual(1000, summary.NumberOfMessagesSkipped); }
public void Skip_and_forward_combination_should_complete_when_done() { var summary = new InMemoryRetry("abc123", RetryType.FailureGroup); summary.Wait(DateTime.UtcNow); summary.Prepare(2000); summary.PrepareBatch(1000); summary.Skip(1000); summary.Forwarding(); summary.BatchForwarded(1000); Assert.AreEqual(RetryState.Completed, summary.RetryState); Assert.AreEqual(1000, summary.NumberOfMessagesForwarded); Assert.AreEqual(1000, summary.NumberOfMessagesSkipped); }