diff options
-rw-r--r-- | test/ruby/test_env.rb | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -122,9 +122,11 @@ class TestEnv < Test::Unit::TestCase assert_equal("foo", ENV.fetch("test")) ENV.delete("test") feature8649 = '[ruby-core:56062] [Feature #8649]' - assert_raise_with_message(KeyError, 'key not found: "test"', feature8649) do ENV.fetch("test") end assert_equal("foo", ENV.fetch("test", "foo")) assert_equal("bar", ENV.fetch("test") { "bar" }) assert_equal("bar", ENV.fetch("test", "foo") { "bar" }) |