mirror of
https://github.com/edgecase/ruby_koans.git
synced 2026-04-15 07:23:19 -04:00
Handle 1.8 VS 1.9 differences in fetch exception.
This commit is contained in:
@@ -23,7 +23,7 @@ class AboutHashes < EdgeCase::Koan
|
||||
def test_accessing_hashes_with_fetch
|
||||
hash = { :one => "uno" }
|
||||
assert_equal "uno", hash.fetch(:one)
|
||||
assert_raise(___(IndexError)) do
|
||||
assert_raise(___(IndexError, KeyError)) do
|
||||
hash.fetch(:doesnt_exist)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user