aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorIlya Etingof <ietingof@redhat.com>2017-02-13 22:38:27 +0100
committerIlya Etingof <ietingof@redhat.com>2017-02-13 22:38:27 +0100
commitbd1b002ddad48e6320721f3aac18f673abd4b4ae (patch)
treec1d7e6c22d693155f5a3cfbb51bbc18e726dbf2f /tests
parenteaf2f6299935f9a4457e606255289c6db5fa464d (diff)
downloadpyasn1-bd1b002ddad48e6320721f3aac18f673abd4b4ae.tar.gz
__reversed__ fixed to return an iterator
Diffstat (limited to 'tests')
-rw-r--r--tests/type/test_univ.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/type/test_univ.py b/tests/type/test_univ.py
index 0d7e0ad..222be58 100644
--- a/tests/type/test_univ.py
+++ b/tests/type/test_univ.py
@@ -375,7 +375,7 @@ class BitStringTestCase(unittest.TestCase):
if sys.version_info[:2] > (2, 4):
def testReverse(self):
- assert reversed(univ.BitString([0, 0, 1])) == univ.BitString([1, 0, 0])
+ assert list(reversed(univ.BitString([0, 0, 1]))) == list(univ.BitString([1, 0, 0]))
def testAsOctets(self):
assert self.b.clone(hexValue='A98A').asOctets() == ints2octs((0xa9, 0x8a)), 'testAsOctets() fails'
@@ -483,8 +483,8 @@ class OctetStringTestCase(unittest.TestCase):
assert str2octs('B') not in s
if sys.version_info[:2] > (2, 4):
- def testReverse(self):
- assert reversed(univ.OctetString('abcd')) == univ.OctetString('dcba')
+ def testReverse(self):
+ assert list(reversed(univ.OctetString('abcd'))) == list(univ.OctetString('dcba'))
class Null(unittest.TestCase):