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

Method test_empty_merges

Lib/test/test_heapq.py:335–339  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

333 self.assertEqual(list(self.module.merge()), [])
334
335 def test_empty_merges(self):
336 # Merging two empty lists (with or without a key) should produce
337 # another empty list.
338 self.assertEqual(list(self.module.merge([], [])), [])
339 self.assertEqual(list(self.module.merge([], [], key=lambda: 6)), [])
340
341 def test_merge_does_not_suppress_index_error(self):
342 # Issue 19018: Heapq.merge suppresses IndexError from user generator

Callers

nothing calls this directly

Calls 3

listClass · 0.85
assertEqualMethod · 0.45
mergeMethod · 0.45

Tested by

no test coverage detected