summaryrefslogtreecommitdiff
path: root/tests/test_crypto.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_crypto.py')
-rw-r--r--tests/test_crypto.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/test_crypto.py b/tests/test_crypto.py
index 699b146..ef3429d 100644
--- a/tests/test_crypto.py
+++ b/tests/test_crypto.py
@@ -1468,7 +1468,7 @@ class _PKeyInteractionTestsMixin:
def signable(self):
"""
- Return something with a `set_pubkey`, `set_pubkey`, and `sign` method.
+ Return something with `set_pubkey` and `sign` methods.
"""
raise NotImplementedError()
@@ -1715,7 +1715,12 @@ class TestX509(_PKeyInteractionTestsMixin):
"""
Create and return a new `X509`.
"""
- return X509()
+ certificate = X509()
+ # Fill in placeholder validity values. signable only expects to call
+ # set_pubkey and sign.
+ certificate.gmtime_adj_notBefore(-24 * 60 * 60)
+ certificate.gmtime_adj_notAfter(24 * 60 * 60)
+ return certificate
def test_type(self):
"""