1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00

Document gotcha about visiting absolute URLs

This commit is contained in:
Trevor Turk 2010-11-22 10:53:53 +00:00
parent b4c228f799
commit 8c2a0d99f6

View file

@ -473,6 +473,12 @@ Gems can use this API to add their own drivers to Capybara.
use plugins which allow you to travel in time, rather than freeze time. use plugins which allow you to travel in time, rather than freeze time.
One such plugin is {Timecop}[http://github.com/jtrupiano/timecop]. One such plugin is {Timecop}[http://github.com/jtrupiano/timecop].
* When using Rack::Test, beware if attempting to visit absolute URLs. For
example, a session might not be shared between visits to <tt>posts_path</tt>
and <tt>posts_url</tt>. If testing an absolute URL in an Action Mailer email,
set <tt>default_url_options</tt> to match the Rails default of
<tt>www.example.com</tt>.
== License: == License:
(The MIT License) (The MIT License)