ruby/test/openssl/test_config.rb
nahi 0322d30623 * test/openssl: backport cosmetic changes from 1.9.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@26836 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2010-03-06 21:41:32 +00:00

16 lines
347 B
Ruby

require 'openssl'
require "test/unit"
class OpenSSL::TestConfig < Test::Unit::TestCase
def test_freeze
c = OpenSSL::Config.new
c['foo'] = [['key', 'value']]
c.freeze
# [ruby-core:18377]
# RuntimeError for 1.9, TypeError for 1.8
assert_raise(TypeError, /frozen/) do
c['foo'] = [['key', 'wrong']]
end
end
end