@@ -60,6 +60,7 @@ public abstract partial class SpecificWeightTestsBase
60
60
protected abstract double KilonewtonsPerCubicMillimeterInOneNewtonPerCubicMeter { get ; }
61
61
protected abstract double KilopoundsForcePerCubicFootInOneNewtonPerCubicMeter { get ; }
62
62
protected abstract double KilopoundsForcePerCubicInchInOneNewtonPerCubicMeter { get ; }
63
+ protected abstract double MeganewtonsPerCubicMeterInOneNewtonPerCubicMeter { get ; }
63
64
protected abstract double NewtonsPerCubicCentimeterInOneNewtonPerCubicMeter { get ; }
64
65
protected abstract double NewtonsPerCubicMeterInOneNewtonPerCubicMeter { get ; }
65
66
protected abstract double NewtonsPerCubicMillimeterInOneNewtonPerCubicMeter { get ; }
@@ -78,6 +79,7 @@ public abstract partial class SpecificWeightTestsBase
78
79
protected virtual double KilonewtonsPerCubicMillimeterTolerance { get { return 1e-5 ; } }
79
80
protected virtual double KilopoundsForcePerCubicFootTolerance { get { return 1e-5 ; } }
80
81
protected virtual double KilopoundsForcePerCubicInchTolerance { get { return 1e-5 ; } }
82
+ protected virtual double MeganewtonsPerCubicMeterTolerance { get { return 1e-5 ; } }
81
83
protected virtual double NewtonsPerCubicCentimeterTolerance { get { return 1e-5 ; } }
82
84
protected virtual double NewtonsPerCubicMeterTolerance { get { return 1e-5 ; } }
83
85
protected virtual double NewtonsPerCubicMillimeterTolerance { get { return 1e-5 ; } }
@@ -100,6 +102,7 @@ public void NewtonPerCubicMeterToSpecificWeightUnits()
100
102
AssertEx . EqualTolerance ( KilonewtonsPerCubicMillimeterInOneNewtonPerCubicMeter , newtonpercubicmeter . KilonewtonsPerCubicMillimeter , KilonewtonsPerCubicMillimeterTolerance ) ;
101
103
AssertEx . EqualTolerance ( KilopoundsForcePerCubicFootInOneNewtonPerCubicMeter , newtonpercubicmeter . KilopoundsForcePerCubicFoot , KilopoundsForcePerCubicFootTolerance ) ;
102
104
AssertEx . EqualTolerance ( KilopoundsForcePerCubicInchInOneNewtonPerCubicMeter , newtonpercubicmeter . KilopoundsForcePerCubicInch , KilopoundsForcePerCubicInchTolerance ) ;
105
+ AssertEx . EqualTolerance ( MeganewtonsPerCubicMeterInOneNewtonPerCubicMeter , newtonpercubicmeter . MeganewtonsPerCubicMeter , MeganewtonsPerCubicMeterTolerance ) ;
103
106
AssertEx . EqualTolerance ( NewtonsPerCubicCentimeterInOneNewtonPerCubicMeter , newtonpercubicmeter . NewtonsPerCubicCentimeter , NewtonsPerCubicCentimeterTolerance ) ;
104
107
AssertEx . EqualTolerance ( NewtonsPerCubicMeterInOneNewtonPerCubicMeter , newtonpercubicmeter . NewtonsPerCubicMeter , NewtonsPerCubicMeterTolerance ) ;
105
108
AssertEx . EqualTolerance ( NewtonsPerCubicMillimeterInOneNewtonPerCubicMeter , newtonpercubicmeter . NewtonsPerCubicMillimeter , NewtonsPerCubicMillimeterTolerance ) ;
@@ -121,6 +124,7 @@ public void FromValueAndUnit()
121
124
AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . KilonewtonPerCubicMillimeter ) . KilonewtonsPerCubicMillimeter , KilonewtonsPerCubicMillimeterTolerance ) ;
122
125
AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . KilopoundForcePerCubicFoot ) . KilopoundsForcePerCubicFoot , KilopoundsForcePerCubicFootTolerance ) ;
123
126
AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . KilopoundForcePerCubicInch ) . KilopoundsForcePerCubicInch , KilopoundsForcePerCubicInchTolerance ) ;
127
+ AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . MeganewtonPerCubicMeter ) . MeganewtonsPerCubicMeter , MeganewtonsPerCubicMeterTolerance ) ;
124
128
AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . NewtonPerCubicCentimeter ) . NewtonsPerCubicCentimeter , NewtonsPerCubicCentimeterTolerance ) ;
125
129
AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . NewtonPerCubicMeter ) . NewtonsPerCubicMeter , NewtonsPerCubicMeterTolerance ) ;
126
130
AssertEx . EqualTolerance ( 1 , SpecificWeight . From ( 1 , SpecificWeightUnit . NewtonPerCubicMillimeter ) . NewtonsPerCubicMillimeter , NewtonsPerCubicMillimeterTolerance ) ;
@@ -143,6 +147,7 @@ public void As()
143
147
AssertEx . EqualTolerance ( KilonewtonsPerCubicMillimeterInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . KilonewtonPerCubicMillimeter ) , KilonewtonsPerCubicMillimeterTolerance ) ;
144
148
AssertEx . EqualTolerance ( KilopoundsForcePerCubicFootInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . KilopoundForcePerCubicFoot ) , KilopoundsForcePerCubicFootTolerance ) ;
145
149
AssertEx . EqualTolerance ( KilopoundsForcePerCubicInchInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . KilopoundForcePerCubicInch ) , KilopoundsForcePerCubicInchTolerance ) ;
150
+ AssertEx . EqualTolerance ( MeganewtonsPerCubicMeterInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . MeganewtonPerCubicMeter ) , MeganewtonsPerCubicMeterTolerance ) ;
146
151
AssertEx . EqualTolerance ( NewtonsPerCubicCentimeterInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . NewtonPerCubicCentimeter ) , NewtonsPerCubicCentimeterTolerance ) ;
147
152
AssertEx . EqualTolerance ( NewtonsPerCubicMeterInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . NewtonPerCubicMeter ) , NewtonsPerCubicMeterTolerance ) ;
148
153
AssertEx . EqualTolerance ( NewtonsPerCubicMillimeterInOneNewtonPerCubicMeter , newtonpercubicmeter . As ( SpecificWeightUnit . NewtonPerCubicMillimeter ) , NewtonsPerCubicMillimeterTolerance ) ;
@@ -165,6 +170,7 @@ public void ConversionRoundTrip()
165
170
AssertEx . EqualTolerance ( 1 , SpecificWeight . FromKilonewtonsPerCubicMillimeter ( newtonpercubicmeter . KilonewtonsPerCubicMillimeter ) . NewtonsPerCubicMeter , KilonewtonsPerCubicMillimeterTolerance ) ;
166
171
AssertEx . EqualTolerance ( 1 , SpecificWeight . FromKilopoundsForcePerCubicFoot ( newtonpercubicmeter . KilopoundsForcePerCubicFoot ) . NewtonsPerCubicMeter , KilopoundsForcePerCubicFootTolerance ) ;
167
172
AssertEx . EqualTolerance ( 1 , SpecificWeight . FromKilopoundsForcePerCubicInch ( newtonpercubicmeter . KilopoundsForcePerCubicInch ) . NewtonsPerCubicMeter , KilopoundsForcePerCubicInchTolerance ) ;
173
+ AssertEx . EqualTolerance ( 1 , SpecificWeight . FromMeganewtonsPerCubicMeter ( newtonpercubicmeter . MeganewtonsPerCubicMeter ) . NewtonsPerCubicMeter , MeganewtonsPerCubicMeterTolerance ) ;
168
174
AssertEx . EqualTolerance ( 1 , SpecificWeight . FromNewtonsPerCubicCentimeter ( newtonpercubicmeter . NewtonsPerCubicCentimeter ) . NewtonsPerCubicMeter , NewtonsPerCubicCentimeterTolerance ) ;
169
175
AssertEx . EqualTolerance ( 1 , SpecificWeight . FromNewtonsPerCubicMeter ( newtonpercubicmeter . NewtonsPerCubicMeter ) . NewtonsPerCubicMeter , NewtonsPerCubicMeterTolerance ) ;
170
176
AssertEx . EqualTolerance ( 1 , SpecificWeight . FromNewtonsPerCubicMillimeter ( newtonpercubicmeter . NewtonsPerCubicMillimeter ) . NewtonsPerCubicMeter , NewtonsPerCubicMillimeterTolerance ) ;
0 commit comments