Example #1
0
 def test_mul(self):
     assert measures.Current("2 A") * measures.Voltage(
         "12 V") == measures.ElectricPower("24 W")
Example #2
0
 def test_mul__super(self):
     assert measures.Current("2 A") * 2 == measures.Current("4 A")
Example #3
0
 def test_truediv__current(self):
     assert measures.ElectricPower("24 W") / measures.Current(
         "4 A") == measures.Voltage("6 V")