summaryrefslogtreecommitdiff
path: root/test/open-uri/test_proxy.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/open-uri/test_proxy.rb')
-rw-r--r--test/open-uri/test_proxy.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/open-uri/test_proxy.rb b/test/open-uri/test_proxy.rb
index a36a63f21f..0cc711a0f3 100644
--- a/test/open-uri/test_proxy.rb
+++ b/test/open-uri/test_proxy.rb
@@ -11,10 +11,10 @@ class TestOpenURIProxy < Test::Unit::TestCase
begin
old = {}
h.each_key {|k| old[k] = ENV[k] }
- h.each {|k, v| ENV[k] = v }
+ ENV.update(h)
yield
ensure
- h.each_key {|k| ENV[k] = old[k] }
+ ENV.update(old)
end
end