MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_normalize

Method test_normalize

Lib/test/test_decimal.py:3520–3527  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3518 self.assertRaises(TypeError, c.next_toward, 1, '2')
3519
3520 def test_normalize(self):
3521 Decimal = self.decimal.Decimal
3522 Context = self.decimal.Context
3523
3524 c = Context()
3525 d = c.normalize(Decimal(10))
3526 self.assertEqual(c.normalize(10), d)
3527 self.assertRaises(TypeError, c.normalize, '10')
3528
3529 def test_number_class(self):
3530 Decimal = self.decimal.Decimal

Callers

nothing calls this directly

Calls 5

normalizeMethod · 0.95
DecimalClass · 0.85
ContextClass · 0.70
assertEqualMethod · 0.45
assertRaisesMethod · 0.45

Tested by

no test coverage detected