public void Test_to_celsius_from_gas_returns_correct_value(double input, double expected) { // Arrange. var inputGas = new GasDouble(input); // Act. var result = inputGas.ToCelsius(); // Assert. result.Should().Be(expected); }
public void Test_to_celsius_from_gas_with_invalid_parameters_throws_argument_out_of_range_exception(double input) { // Arrange. var inputGas = new GasDouble(input); // Act. var result = Assert.Throws <ArgumentOutOfRangeException>(() => inputGas.ToCelsius()); // Assert. result.Message.Should().Contain("Temp too low or too high for gas mark!"); }