提交 2ded9c65 编写于 作者: Y yui-knk

Suppress warnings of `assigned but unused variable`

上级 37423e4f
......@@ -146,7 +146,7 @@ def test_only_set_charset_still_defaults_to_text_html
test "cookies" do
@response.set_cookie("user_name", :value => "david", :path => "/")
status, headers, body = @response.to_a
_status, headers, _body = @response.to_a
assert_equal "user_name=david; path=/", headers["Set-Cookie"]
assert_equal({"user_name" => "david"}, @response.cookies)
end
......@@ -154,7 +154,7 @@ def test_only_set_charset_still_defaults_to_text_html
test "multiple cookies" do
@response.set_cookie("user_name", :value => "david", :path => "/")
@response.set_cookie("login", :value => "foo&bar", :path => "/", :expires => Time.utc(2005, 10, 10,5))
status, headers, body = @response.to_a
_status, headers, _body = @response.to_a
assert_equal "user_name=david; path=/\nlogin=foo%26bar; path=/; expires=Mon, 10 Oct 2005 05:00:00 -0000", headers["Set-Cookie"]
assert_equal({"login" => "foo&bar", "user_name" => "david"}, @response.cookies)
end
......@@ -163,7 +163,6 @@ def test_only_set_charset_still_defaults_to_text_html
@response.set_cookie("user_name", :value => "david", :path => "/")
@response.set_cookie("login", :value => "foo&bar", :path => "/", :expires => Time.utc(2005, 10, 10,5))
@response.delete_cookie("login")
status, headers, body = @response.to_a
assert_equal({"user_name" => "david", "login" => nil}, @response.cookies)
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册