diff options
author | Erik Trauschke <erik.trauschke@gmail.com> | 2015-10-20 08:18:00 -0700 |
---|---|---|
committer | Erik Trauschke <erik.trauschke@gmail.com> | 2015-10-20 08:18:00 -0700 |
commit | c8ab2ea92fe43d1ff64d7463c61fa9ef34cce7d8 (patch) | |
tree | d3ed0f8b77f4f978ee847585e5b1ae1a9994270b /tests/test_x509_ext.py | |
parent | c219b962f8f02f85edf2a3452fe4136b1211f807 (diff) | |
parent | 018a9659924c5ffe548d716295a4292c6929c341 (diff) | |
download | cryptography-c8ab2ea92fe43d1ff64d7463c61fa9ef34cce7d8.tar.gz cryptography-c8ab2ea92fe43d1ff64d7463c61fa9ef34cce7d8.tar.bz2 cryptography-c8ab2ea92fe43d1ff64d7463c61fa9ef34cce7d8.zip |
Merge branch 'master' into crl_ossl_backend
Diffstat (limited to 'tests/test_x509_ext.py')
-rw-r--r-- | tests/test_x509_ext.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/test_x509_ext.py b/tests/test_x509_ext.py index 1bc14620..8f469366 100644 --- a/tests/test_x509_ext.py +++ b/tests/test_x509_ext.py @@ -857,6 +857,20 @@ class TestExtensions(object): assert ext is not None assert isinstance(ext.value, x509.BasicConstraints) + def test_repr(self, backend): + cert = _load_cert( + os.path.join( + "x509", "custom", "basic_constraints_not_critical.pem" + ), + x509.load_pem_x509_certificate, + backend + ) + assert repr(cert.extensions) == ( + "<Extensions([<Extension(oid=<ObjectIdentifier(oid=2.5.29.19, name" + "=basicConstraints)>, critical=False, value=<BasicConstraints(ca=F" + "alse, path_length=None)>)>])>" + ) + @pytest.mark.requires_backend_interface(interface=RSABackend) @pytest.mark.requires_backend_interface(interface=X509Backend) |