MCPcopy Create free account
hub / github.com/ipython/traitlets / TestCFloat

Class TestCFloat

tests/test_traitlets.py:1532–1540  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1530
1531
1532class TestCFloat(TraitTestBase):
1533 obj = CFloatTrait()
1534
1535 _default_value = 99.0
1536 _good_values = [10, 10.0, 10.5, "10.0", "10", "-10"]
1537 _bad_values = ["ten", [10], {"ten": 10}, (10,), None, 1j, 200.1, "200.1"]
1538
1539 def coerce(self, v):
1540 return float(v)
1541
1542
1543class ComplexTrait(HasTraits):

Callers

nothing calls this directly

Calls 1

CFloatTraitClass · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…