MCPcopy Create free account
hub / github.com/rthalley/dnspython / test_casting

Method test_casting

tests/test_serial.py:86–92  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

84 self.assertRaises(ValueError, bad2)
85
86 def test_casting(self):
87 self.assertTrue(S8(0) == 0)
88 self.assertTrue(S8(0) != 1)
89 self.assertTrue(S8(0) < 1)
90 self.assertTrue(S8(0) <= 1)
91 self.assertTrue(S8(0) > 255)
92 self.assertTrue(S8(0) >= 255)
93
94 def test_uncastable(self):
95 self.assertRaises(ValueError, lambda: S8(0) + "a")

Callers

nothing calls this directly

Calls 1

S8Function · 0.85

Tested by

no test coverage detected