Add a simple test for X509.digest
diff --git a/test/test_crypto.py b/test/test_crypto.py
index 0ab8666..4c66c62 100644
--- a/test/test_crypto.py
+++ b/test/test_crypto.py
@@ -431,3 +431,14 @@
         to it.
         """
         self._setBoundTest("After")
+
+
+    def test_digest(self):
+        """
+        L{X509.digest} returns a string giving ":"-separated hex-encoded words
+        of the digest of the certificate.
+        """
+        cert = X509()
+        self.assertEqual(
+            cert.digest("md5"),
+            "A8:EB:07:F8:53:25:0A:F2:56:05:C5:A5:C4:C4:C7:15")