summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/openssl/test_ssl.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/openssl/test_ssl.rb b/test/openssl/test_ssl.rb
index 0f740851b4..28f5141cb0 100644
--- a/test/openssl/test_ssl.rb
+++ b/test/openssl/test_ssl.rb
@@ -1064,7 +1064,9 @@ if OpenSSL::OPENSSL_VERSION_NUMBER >= 0x10002000
end
end
-if OpenSSL::OPENSSL_VERSION_NUMBER > 0x10001000
+if OpenSSL::OPENSSL_VERSION_NUMBER > 0x10001000 &&
+ OpenSSL::SSL::SSLContext.method_defined?(:npn_select_cb)
+ # NPN may be disabled by OpenSSL configure option
def test_npn_protocol_selection_ary
advertised = ["http/1.1", "spdy/2"]