diff options
author | Raymond Hettinger <python@rcn.com> | 2009-02-14 00:25:51 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2009-02-14 00:25:51 (GMT) |
commit | a4038038c69c72f96f1c7d435d50818c46892591 (patch) | |
tree | d766cc7067bdf647a2ee974bc4e20d77bd245ddc /Lib | |
parent | 544c3e19e6b6c8162c45a22594c6b929fd14f427 (diff) | |
download | cpython-a4038038c69c72f96f1c7d435d50818c46892591.zip cpython-a4038038c69c72f96f1c7d435d50818c46892591.tar.gz cpython-a4038038c69c72f96f1c7d435d50818c46892591.tar.bz2 |
Add keyword argument support to itertools.count().
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_itertools.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_itertools.py b/Lib/test/test_itertools.py index 043eaee..ce5c898 100644 --- a/Lib/test/test_itertools.py +++ b/Lib/test/test_itertools.py @@ -347,6 +347,8 @@ class TestBasicOps(unittest.TestCase): def test_count_with_stride(self): self.assertEqual(zip('abc',count(2,3)), [('a', 2), ('b', 5), ('c', 8)]) + self.assertEqual(zip('abc',count(start=2,step=3)), + [('a', 2), ('b', 5), ('c', 8)]) self.assertEqual(zip('abc',count(2,0)), [('a', 2), ('b', 2), ('c', 2)]) self.assertEqual(zip('abc',count(2,1)), [('a', 2), ('b', 3), ('c', 4)]) self.assertEqual(take(20, count(maxsize-15, 3)), take(20, range(maxsize-15, maxsize+100, 3))) |