MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_and

Method test_and

Lib/test/test_set.py:145–154  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

143 self.assertTrue(actual is True or actual is False)
144
145 def test_and(self):
146 i = self.s.intersection(self.otherword)
147 self.assertEqual(self.s & set(self.otherword), i)
148 self.assertEqual(self.s & frozenset(self.otherword), i)
149 try:
150 self.s & self.otherword
151 except TypeError:
152 pass
153 else:
154 self.fail("s&t did not screen-out general iterables")
155
156 def test_difference(self):
157 i = self.s.difference(self.otherword)

Callers

nothing calls this directly

Calls 4

setFunction · 0.85
intersectionMethod · 0.45
assertEqualMethod · 0.45
failMethod · 0.45

Tested by

no test coverage detected