def test_densityScale(self): dim = Nondimensional() dim._configure() dim.setDensityScale(2.0 * kilogram / meter**3) self.assertEqual(1.0 * meter, dim.getLengthScale()) self.assertEqual(1.0 * pascal, dim.getPressureScale()) self.assertEqual(1.0 * second, dim.getTimeScale()) self.assertEqual(2.0 * kilogram / meter**3, dim.getDensityScale())
def test_constructor(self): dim = Nondimensional() dim._configure() self.assertEqual(1.0 * meter, dim.getLengthScale()) self.assertEqual(1.0 * pascal, dim.getPressureScale()) self.assertEqual(1.0 * second, dim.getTimeScale()) self.assertEqual(1.0 * kilogram / meter**3, dim.getDensityScale()) self.assertEqual(1.0 * kelvin, dim.getTemperatureScale())