File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -147,10 +147,6 @@ def readwrite_loop(context, ssl)
147147 ssl . close rescue nil
148148 end
149149
150- def java_version
151- java . lang . System . get_property ( 'java.version' ) [ 2 ] . to_i
152- end
153-
154150 TEST_KEY_RSA1024 = <<-_end_of_pem_
155151-----BEGIN RSA PRIVATE KEY-----
156152MIICXgIBAAKBgQDLwsSw1ECnPtT+PkOgHhcGA71nwC2/nL85VBGnRqDxOqjVh7Cx
Original file line number Diff line number Diff line change @@ -96,8 +96,6 @@ def test_ssl_version_tlsv1
9696 end
9797
9898 def test_ssl_version_tlsv1_1
99- return if java_version < 7 # TLS1_1 is not supported by JDK 6
100-
10199 ctx_proc = Proc . new do |ctx |
102100 ctx . ssl_version = "TLSv1_1"
103101 end
@@ -108,11 +106,9 @@ def test_ssl_version_tlsv1_1
108106 assert_equal ( "TLSv1.1" , ssl . ssl_version )
109107 ssl . close
110108 end
111- end
109+ end unless java6? # TLS1_1 is not supported by JDK 6
112110
113111 def test_ssl_version_tlsv1_2
114- return if java_version < 7 # TLS1_2 is not supported by JDK 6
115-
116112 ctx_proc = Proc . new do |ctx |
117113 ctx . ssl_version = "TLSv1_2"
118114 end
@@ -123,5 +119,6 @@ def test_ssl_version_tlsv1_2
123119 assert_equal ( "TLSv1.2" , ssl . ssl_version )
124120 ssl . close
125121 end
126- end
122+ end unless java6? # TLS1_2 is not supported by JDK 6
123+
127124end
You can’t perform that action at this time.
0 commit comments