MCPcopy Index your code
hub / github.com/python/cpython / test_normalize

Method test_normalize

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

Source from the content-addressed store, hash-verified

3513 self.assertRaises(TypeError, c.next_toward, 1, '2')
3514
3515 def test_normalize(self):
3516 Decimal = self.decimal.Decimal
3517 Context = self.decimal.Context
3518
3519 c = Context()
3520 d = c.normalize(Decimal(10))
3521 self.assertEqual(c.normalize(10), d)
3522 self.assertRaises(TypeError, c.normalize, '10')
3523
3524 def test_number_class(self):
3525 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