diff options
author | Raymond Hettinger <python@rcn.com> | 2008-01-22 23:25:35 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2008-01-22 23:25:35 (GMT) |
commit | 1dfde1ddc0e1980d67bd19e187252d4e52b4f7ce (patch) | |
tree | 365fcd0e0d95e4ff612ca7184d441e6184f8b203 /Lib/test/test_iter.py | |
parent | 86def6cb2b8d6d8c7f239795fa7af57c97a5890d (diff) | |
download | cpython-1dfde1ddc0e1980d67bd19e187252d4e52b4f7ce.zip cpython-1dfde1ddc0e1980d67bd19e187252d4e52b4f7ce.tar.gz cpython-1dfde1ddc0e1980d67bd19e187252d4e52b4f7ce.tar.bz2 |
Replace map(None, *iterables) with zip(*iterables).
Diffstat (limited to 'Lib/test/test_iter.py')
-rw-r--r-- | Lib/test/test_iter.py | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/Lib/test/test_iter.py b/Lib/test/test_iter.py index 07a3bf2..d861dcd 100644 --- a/Lib/test/test_iter.py +++ b/Lib/test/test_iter.py @@ -382,13 +382,10 @@ class TestCase(unittest.TestCase): # Test map()'s use of iterators. def test_builtin_map(self): - self.assertEqual(list(map(None, SequenceClass(5))), - [(0,), (1,), (2,), (3,), (4,)]) self.assertEqual(list(map(lambda x: x+1, SequenceClass(5))), list(range(1, 6))) d = {"one": 1, "two": 2, "three": 3} - self.assertEqual(list(map(None, d)), [(k,) for k in d]) self.assertEqual(list(map(lambda k, d=d: (k, d[k]), d)), list(d.items())) dkeys = list(d.keys()) @@ -396,11 +393,6 @@ class TestCase(unittest.TestCase): i, i < len(d) and dkeys[i] or None) for i in range(3)] - self.assertEqual(list(map(None, - d, - SequenceClass(5), - iter(d.keys()))), - expected) f = open(TESTFN, "w") try: |