public DefaultGraphiteTcpClient( GraphiteOptions options, ClientPolicy clientPolicy) { _options = options; _backOffPeriod = clientPolicy.BackoffPeriod; _failuresBeforeBackoff = clientPolicy.FailuresBeforeBackoff; _sendTimeout = clientPolicy.Timeout.Milliseconds; _failureAttempts = 0; }
public void Base_address_cannot_be_null() { // Arrange Action action = () => { // Act var settings = new GraphiteOptions(null); }; // Assert action.Should().Throw <ArgumentNullException>(); }
public void Can_determine_protocol(string address, Protocol expected) { var settings = new GraphiteOptions(new Uri(address)); settings.Protocol.Should().Be(expected); }