From 67893143133a9f76fd98b812df0982017cd05833 Mon Sep 17 00:00:00 2001 From: Ilya Etingof Date: Mon, 28 Aug 2017 00:37:59 +0200 Subject: fixed CharType(OctetStringType()) instantiation --- tests/type/test_char.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/type/test_char.py b/tests/type/test_char.py index 4b17127..82b612b 100644 --- a/tests/type/test_char.py +++ b/tests/type/test_char.py @@ -61,11 +61,12 @@ class AbstractStringTestCase: def testInit(self): assert self.asn1Type(self.pythonString) == self.pythonString assert self.asn1Type(self.pythonString.encode(self.encoding)) == self.pythonString + assert self.asn1Type(univ.OctetString(self.pythonString.encode(self.encoding))) == self.pythonString assert self.asn1Type(self.initializer, encoding=self.encoding) == self.pythonString def testInitFromAsn1(self): - assert self.asn1Type(self.asn1Type(self.pythonString)) == self.pythonString - assert self.asn1Type(univ.OctetString(self.pythonString.encode(self.encoding), encoding=self.encoding)) == self.pythonString + assert self.asn1Type(self.asn1Type(self.pythonString)) == self.pythonString + assert self.asn1Type(univ.OctetString(self.pythonString.encode(self.encoding), encoding=self.encoding)) == self.pythonString def testAsOctets(self): assert self.asn1String.asOctets() == self.pythonString.encode(self.encoding), 'testAsOctets() fails' -- cgit v1.2.3