public void AverageSpeedTestThrowingException(AvgSpeed.Speedometer instance, UnitsNet.Duration duration, AvgSpeed.ITrack track, Type expected) { Assert.Throws(expected, () => instance.AverageSpeed(duration, track)); }
public void AverageSpeedTest(AvgSpeed.Speedometer instance, UnitsNet.Duration duration, AvgSpeed.ITrack track, UnitsNet.Speed expected) { UnitsNet.Speed actual = instance.AverageSpeed(duration, track); Assert.AreEqual(expected.KilometersPerHour, actual.KilometersPerHour, 1e-8); }