def test_call_i32_i64_f32_f64_f64(self): self.assertEqual( round( Instance(TEST_BYTES).call('i32_i64_f32_f64_f64', [ Value.i32(1), Value.i64(2), Value.f32(3.4), Value.f64(5.6) ]), 6), 1 + 2 + 3.4 + 5.6)
def test_call_f64_f64(self): self.assertEqual( Instance(TEST_BYTES).call('f64_f64', [Value.f64(7.)]), 7.)
def test_f64_auto_cast(): assert repr(Value.f64(42)) == 'F64(42.0)'
def test_f64(): assert repr(Value.f64(4.2)) == 'F64(4.2)'
def test_f64_auto_cast(self): self.assertEqual(repr(Value.f64(42)), 'F64(42.0)')
def test_f64(self): self.assertEqual(repr(Value.f64(4.2)), 'F64(4.2)')