Class: RefererServlet

Inherits:
WEBrick::HTTPServlet::AbstractServlet
  • Object
show all
Defined in:
lib/mechanize/test_case.rb

Instance Method Summary collapse

Instance Method Details

#do_GET(req, res) ⇒ Object



446
447
448
449
# File 'lib/mechanize/test_case.rb', line 446

def do_GET(req, res)
  res['Content-Type'] = "text/html"
  res.body = req['Referer'] || ''
end

#do_POST(req, res) ⇒ Object



451
452
453
454
# File 'lib/mechanize/test_case.rb', line 451

def do_POST(req, res)
  res['Content-Type'] = "text/html"
  res.body = req['Referer'] || ''
end