public void Constructor_GivenNullResults_DoesNotSetChecks() { IEnumerable <HealthCheckResult> results = null; var response = new HealthResponse(results); response.Checks.Should().BeNull(); response.GetChecks().Should().BeEmpty(); }
public void Constructor_GivenEmptyResults_DoesNotSetChecks() { var results = Enumerable.Empty <HealthCheckResult>(); var response = new HealthResponse(results); response.Checks.Should().BeNull(); response.GetChecks().Should().BeEmpty(); }
public void Constructor_SetsChecks() { var results = new[] { new HealthCheckResult(), new HealthCheckResult() }; var response = new HealthResponse(results); response.Checks.Should().NotBeNull(); response.GetChecks().Should().BeEquivalentTo(results); }