summaryrefslogtreecommitdiff
path: root/test/openssl
diff options
context:
space:
mode:
authorKazuki Yamaguchi <k@rhe.jp>2021-11-11 17:59:22 +0900
committerKazuki Yamaguchi <k@rhe.jp>2021-11-11 17:59:22 +0900
commitcd51bf61a2178a73219f7884792dfb82ca64c082 (patch)
treee1175fb1625a96b8de2607389c58d37f54cccbdc /test/openssl
parent52ab9bbee918c63faad32e3851b162691b984d40 (diff)
test/openssl/test_ssl: adjust certificate expiry date
test_connect_certificate_verify_failed_exception_message occasionally fails. Is it possible that OpenSSL sees a different clock from Ruby by more than 10 seconds? http://ci.rvm.jp/logfiles/brlog.trunk-random0.20211111-072828 Let's give more time after the certificate expiration date to see if this fixes the flakiness. We had similar occasional failures in test_x509store.rb before, which disappeared after ruby/ruby commit 7930a352a57c and ruby/openssl commit fb2fcbb13734.
Diffstat (limited to 'test/openssl')
-rw-r--r--test/openssl/test_ssl.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/openssl/test_ssl.rb b/test/openssl/test_ssl.rb
index 70c46a9347..ef9958aee5 100644
--- a/test/openssl/test_ssl.rb
+++ b/test/openssl/test_ssl.rb
@@ -1002,8 +1002,9 @@ class OpenSSL::TestSSL < OpenSSL::SSLTestCase
}
ctx_proc = proc { |ctx|
+ now = Time.now
ctx.cert = issue_cert(@svr, @svr_key, 30, [], @ca_cert, @ca_key,
- not_before: Time.now-100, not_after: Time.now-10)
+ not_before: now - 7200, not_after: now - 3600)
}
start_server(ignore_listener_error: true, ctx_proc: ctx_proc) { |port|
store = OpenSSL::X509::Store.new