aboutsummaryrefslogtreecommitdiffstats
path: root/tests/x509/test_x509_crlbuilder.py
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2019-01-22 06:59:06 -0600
committerAlex Gaynor <alex.gaynor@gmail.com>2019-01-22 07:59:06 -0500
commit2e9c7df922edbc59981a2c0fdb6ea4f15fdd8afc (patch)
treeb37d095c076db48ab3e7cf4e68a4f6894a30b6d6 /tests/x509/test_x509_crlbuilder.py
parent767fa8511caade795457b23ea9d3d85af1ed12bb (diff)
downloadcryptography-2e9c7df922edbc59981a2c0fdb6ea4f15fdd8afc.tar.gz
cryptography-2e9c7df922edbc59981a2c0fdb6ea4f15fdd8afc.tar.bz2
cryptography-2e9c7df922edbc59981a2c0fdb6ea4f15fdd8afc.zip
allow asn1 times of 1950-01-01 and later. (#4728)
* allow asn1 times of 1950-01-01 and later. * add a test * pretty up the test
Diffstat (limited to 'tests/x509/test_x509_crlbuilder.py')
-rw-r--r--tests/x509/test_x509_crlbuilder.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/x509/test_x509_crlbuilder.py b/tests/x509/test_x509_crlbuilder.py
index e90fd3fd..5f220bca 100644
--- a/tests/x509/test_x509_crlbuilder.py
+++ b/tests/x509/test_x509_crlbuilder.py
@@ -62,10 +62,10 @@ class TestCertificateRevocationListBuilder(object):
with pytest.raises(TypeError):
builder.last_update("notadatetime")
- def test_last_update_before_unix_epoch(self):
+ def test_last_update_before_1950(self):
builder = x509.CertificateRevocationListBuilder()
with pytest.raises(ValueError):
- builder.last_update(datetime.datetime(1960, 8, 10))
+ builder.last_update(datetime.datetime(1940, 8, 10))
def test_set_last_update_twice(self):
builder = x509.CertificateRevocationListBuilder().last_update(
@@ -97,10 +97,10 @@ class TestCertificateRevocationListBuilder(object):
with pytest.raises(TypeError):
builder.next_update("notadatetime")
- def test_next_update_before_unix_epoch(self):
+ def test_next_update_before_1950(self):
builder = x509.CertificateRevocationListBuilder()
with pytest.raises(ValueError):
- builder.next_update(datetime.datetime(1960, 8, 10))
+ builder.next_update(datetime.datetime(1940, 8, 10))
def test_set_next_update_twice(self):
builder = x509.CertificateRevocationListBuilder().next_update(