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

Method test_member_length

Lib/test/test_enum.py:3906–3910  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3904 self.assertEqual(list(Color.WHITE), [Color.RED, Color.GREEN, Color.BLUE])
3905
3906 def test_member_length(self):
3907 self.assertEqual(self.Color.__len__(self.Color.BLACK), 0)
3908 self.assertEqual(self.Color.__len__(self.Color.GREEN), 1)
3909 self.assertEqual(self.Color.__len__(self.Color.PURPLE), 2)
3910 self.assertEqual(self.Color.__len__(self.Color.BLANCO), 3)
3911
3912 def test_number_reset_and_order_cleanup(self):
3913 class Confused(Flag):

Callers

nothing calls this directly

Calls 2

assertEqualMethod · 0.45
__len__Method · 0.45

Tested by

no test coverage detected