1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Test Hash#except can receive more than one argument.

This commit is contained in:
Edward Tsech 2012-05-11 12:09:57 +02:00
parent 9b4514c3b8
commit 21190f37f8

View file

@ -500,6 +500,12 @@ class HashExtTest < ActiveSupport::TestCase
assert_equal expected, original
end
def test_except_with_more_than_one_argument
original = { :a => 'x', :b => 'y', :c => 10 }
expected = { :a => 'x' }
assert_equal expected, original.except(:b, :c)
end
def test_except_with_original_frozen
original = { :a => 'x', :b => 'y' }
original.freeze