public void Settings_are_required() { // Arrange Action action = () => { // Act var unused = new DefaultDatadogHttpClient(new HttpClient(), null, new HttpPolicy()); }; // Assert action.Should().Throw <ArgumentNullException>(); }
public void Http_policy_is_required() { // Arrange Action action = () => { var settings = new MetricsReportingDatadogOptions { Datadog = new DatadogOptions { BaseUri = new Uri("http://localhost"), ApiKey = "123" }, HttpPolicy = new HttpPolicy() }; // Act var unused = new DefaultDatadogHttpClient(new HttpClient(), settings.Datadog, null); }; // Assert action.Should().Throw <ArgumentNullException>(); }