Skip to content

Commit 902228b

Browse files
committed
Merge pull request shakacode#205 from mapreal19/capybara-assets-host
Adds Capybara.asset_host
2 parents 43aa4fb + c6fe00f commit 902228b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

spec/rails_helper.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@
77
require "rspec/rails"
88
require "capybara/rspec"
99
require "capybara-screenshot/rspec"
10+
11+
# This will insert a <base> tag with the asset host into the pages created by
12+
# save_and_open_page, meaning that relative links will be loaded from the
13+
# development server if it is running.
14+
Capybara.asset_host = "http://localhost:4000"
15+
1016
# Add additional requires below this line. Rails is not loaded until this point!
1117

1218
# Requires supporting ruby files with custom matchers and macros, etc, in

0 commit comments

Comments
 (0)