Ejemplo n.º 1
0
        public void AmountToStandardUnitConverter_InstanceUnit_ReturnsGigaTimesOriginalValue()
        {
            var expected = AmountConverter.ToAmountType(iValue: 1.0e9);
            var actual   = this.instance.ConvertAmountToStandardUnit((float)AmountConverter.ToAmountType(iValue: 1.0d));

            AmountAssert.AreEqual(expected, actual);
        }
Ejemplo n.º 2
0
 public static void AreEqual <Q1, Q2>(IMeasureDoublet <Q1, Q2> expected, IMeasureDoublet <Q1, Q2> actual)
     where Q1 : class, IQuantity <Q1>, new()
     where Q2 : class, IQuantity <Q2>, new()
 {
     Assert.AreEqual(expected.X.Unit, actual.X.Unit);
     Assert.AreEqual(expected.Y.Unit, actual.Y.Unit);
     AmountAssert.AreEqual(expected.X.Amount, actual.X.Amount);
     AmountAssert.AreEqual(expected.Y.Amount, actual.Y.Amount);
 }