added test to check validation of digest
diff --git a/OpenSSL/test/test_crypto.py b/OpenSSL/test/test_crypto.py
index 1747b7e..2e834af 100644
--- a/OpenSSL/test/test_crypto.py
+++ b/OpenSSL/test/test_crypto.py
@@ -2967,6 +2967,10 @@
         text = _runopenssl(dumped_crl, b"crl", b"-noout", b"-text")
         text.index(b('Signature Algorithm: md5'))
 
+        # test that unknown digest types fail
+        self.assertRaises(
+            ValueError, crl.export, self.cert, self.pkey, digest="strange-digest")
+
 
     def test_export_invalid(self):
         """