Class: RefreshWithEmptyUrl
- Inherits:
-
WEBrick::HTTPServlet::AbstractServlet
- Object
- WEBrick::HTTPServlet::AbstractServlet
- RefreshWithEmptyUrl
- Defined in:
- lib/mechanize/test_case.rb
Constant Summary collapse
- @@count =
0
Instance Method Summary collapse
Instance Method Details
#do_GET(req, res) ⇒ Object
462 463 464 465 466 467 468 469 470 |
# File 'lib/mechanize/test_case.rb', line 462 def do_GET(req, res) res['Content-Type'] = "text/html" @@count += 1 if @@count > 1 res['Refresh'] = "0; url=http://localhost/index.html"; else res['Refresh'] = "0; url="; end end |