diff options
author | Zachary Scott <e@zzak.io> | 2015-02-09 17:15:59 -0800 |
---|---|---|
committer | Zachary Scott <e@zzak.io> | 2015-02-09 17:15:59 -0800 |
commit | 407935337826769827f23e639568d3927c0440d8 (patch) | |
tree | 715e9737b7f283dc84ffbafc8c5a59e091ef11d7 /test/test_cipher.rb | |
parent | 9bfd84919fb1ebf0b8b2b284e6323539df4a129b (diff) | |
download | ruby-openssl-407935337826769827f23e639568d3927c0440d8.tar.gz |
Upstream ruby/ruby@9f9034bba196233607d62442eebf401eca4f2257
Diffstat (limited to 'test/test_cipher.rb')
-rw-r--r-- | test/test_cipher.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/test/test_cipher.rb b/test/test_cipher.rb index 30220d16..81ded0ae 100644 --- a/test/test_cipher.rb +++ b/test/test_cipher.rb @@ -104,7 +104,12 @@ class OpenSSL::TestCipher < Test::Unit::TestCase def test_ciphers OpenSSL::Cipher.ciphers.each{|name| next if /netbsd/ =~ RUBY_PLATFORM && /idea|rc5/i =~ name - assert(OpenSSL::Cipher::Cipher.new(name).is_a?(OpenSSL::Cipher::Cipher)) + begin + assert_kind_of(OpenSSL::Cipher::Cipher, OpenSSL::Cipher::Cipher.new(name)) + rescue OpenSSL::Cipher::CipherError => e + next if /wrap\z/ =~ name and e.message == 'wrap mode not allowed' + raise + end } end |