mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
[Bug #6540]
* test/ruby/test_rand.rb (TestRand#test_initialize_frozen): add missing test for [Bug #6540] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36185 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
48fc312150
commit
91fcdd1865
1 changed files with 8 additions and 0 deletions
|
@ -485,6 +485,14 @@ END
|
|||
}
|
||||
end
|
||||
|
||||
def test_initialize_frozen
|
||||
r = Random.new(0)
|
||||
r.freeze
|
||||
assert_raise(RuntimeError, '[Bug #6540]') do
|
||||
r.__send__(:initialize, r)
|
||||
end
|
||||
end
|
||||
|
||||
def test_marshal_load_frozen
|
||||
r = Random.new(0)
|
||||
d = r.marshal_dump
|
||||
|
|
Loading…
Add table
Reference in a new issue