Eliminate the double reverse option. It's only use case

was academic and it was potentially confusing to use.
This commit is contained in:
Raymond Hettinger 2004-03-10 08:32:47 +00:00
parent a6366fe085
commit d2c36261a2
2 changed files with 2 additions and 17 deletions

View file

@ -141,11 +141,8 @@ class TestReversed(unittest.TestCase):
x = xrange(1)
self.assertEqual(type(reversed(x)), type(iter(x)))
def test_double_reverse(self):
s = 'hello'
self.assertEqual(list(reversed(reversed(s))), list(s))
def test_len(self):
# This is an implementation detail, not an interface requirement
s = 'hello'
self.assertEqual(len(reversed(s)), len(s))