diff options
author | Raymond Hettinger <python@rcn.com> | 2009-02-24 11:25:35 +0000 |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2009-02-24 11:25:35 +0000 |
commit | aefb33d04a89929374648892077a6f665f277558 (patch) | |
tree | 49239374cff23ab8813eaaec7207d987b346aa96 /Lib/test/test_collections.py | |
parent | be89a450d84d3e4bdcadbd2af4c9be51fae61d5b (diff) | |
download | cpython-aefb33d04a89929374648892077a6f665f277558.tar.gz |
range() should have been registered as a Sequence.
Needs to be backported to 2.6, 2.7, and 3.0.
Diffstat (limited to 'Lib/test/test_collections.py')
-rw-r--r-- | Lib/test/test_collections.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_collections.py b/Lib/test/test_collections.py index 1127910ac8..c73d89bdfc 100644 --- a/Lib/test/test_collections.py +++ b/Lib/test/test_collections.py @@ -406,6 +406,8 @@ class TestCollectionABCs(ABCTestCase): for sample in [tuple, list, bytes, str]: self.failUnless(isinstance(sample(), Sequence)) self.failUnless(issubclass(sample, Sequence)) + self.failUnless(isinstance(range(10), Sequence)) + self.failUnless(issubclass(range, Sequence)) self.failUnless(issubclass(str, Sequence)) self.validate_abstract_methods(Sequence, '__contains__', '__iter__', '__len__', '__getitem__') |