Exemplo n.º 1
0
        public void ConversionRoundTrip()
        {
            AreaDensity kilogrampersquaremeter = AreaDensity.FromKilogramsPerSquareMeter(1);

            AssertEx.EqualTolerance(1, AreaDensity.FromGramPerSquareMeters(kilogrampersquaremeter.GramPerSquareMeters).KilogramsPerSquareMeter, GramPerSquareMetersTolerance);
            AssertEx.EqualTolerance(1, AreaDensity.FromKilogramPerSquareCentimeters(kilogrampersquaremeter.KilogramPerSquareCentimeters).KilogramsPerSquareMeter, KilogramPerSquareCentimetersTolerance);
            AssertEx.EqualTolerance(1, AreaDensity.FromKilogramsPerSquareMeter(kilogrampersquaremeter.KilogramsPerSquareMeter).KilogramsPerSquareMeter, KilogramsPerSquareMeterTolerance);
            AssertEx.EqualTolerance(1, AreaDensity.FromKipsPerSquareFoots(kilogrampersquaremeter.KipsPerSquareFoots).KilogramsPerSquareMeter, KipsPerSquareFootsTolerance);
            AssertEx.EqualTolerance(1, AreaDensity.FromKipsPerSquareInchs(kilogrampersquaremeter.KipsPerSquareInchs).KilogramsPerSquareMeter, KipsPerSquareInchsTolerance);
        }
Exemplo n.º 2
0
 public void NumberToKipsPerSquareFootsTest() =>
 Assert.Equal(AreaDensity.FromKipsPerSquareFoots(2), 2.KipsPerSquareFoots());