public void OnError_ErrorPolicyBuildAction_ErrorPolicySet() { var builder = new TestConsumerEndpointBuilder(); var endpoint = builder.OnError(errorPolicy => errorPolicy.Retry(5).ThenSkip()).Build(); endpoint.ErrorPolicy.Should().BeOfType <ErrorPolicyChain>(); }
public void OnError_ErrorPolicy_ErrorPolicySet() { var builder = new TestConsumerEndpointBuilder(); var errorPolicy = new RetryErrorPolicy(); var endpoint = builder.OnError(errorPolicy).Build(); endpoint.ErrorPolicy.Should().BeSameAs(errorPolicy); }