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

Method test_incremental_ops

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

Source from the content-addressed store, hash-verified

51 self.assertFalse(S8(129) > S8(1))
52
53 def test_incremental_ops(self):
54 v = S8(255)
55 v += 1
56 self.assertEqual(v, 0)
57 v = S8(255)
58 v += S8(1)
59 self.assertEqual(v, 0)
60 v = S8(0)
61 v -= 1
62 self.assertEqual(v, 255)
63 v = S8(0)
64 v -= S8(1)
65 self.assertEqual(v, 255)
66
67 def test_sub(self):
68 self.assertEqual(S8(0) - S8(1), S8(255))

Callers

nothing calls this directly

Calls 1

S8Function · 0.85

Tested by

no test coverage detected