mirror of
https://github.com/thoughtbot/capybara-webkit
synced 2023-03-27 23:22:28 -04:00
Capybara spec_helper is in capybara/spec
This commit is contained in:
parent
d79a6ba514
commit
15bb56012e
1 changed files with 1 additions and 9 deletions
|
@ -9,14 +9,6 @@ $LOAD_PATH << File.join(PROJECT_ROOT, 'lib')
|
|||
|
||||
Dir[File.join(PROJECT_ROOT, 'spec', 'support', '**', '*.rb')].each { |file| require(file) }
|
||||
|
||||
spec_dir = nil
|
||||
$:.detect do |dir|
|
||||
if File.exists? File.join(dir, "capybara.rb")
|
||||
spec_dir = File.expand_path(File.join(dir,"..","spec"))
|
||||
$:.unshift( spec_dir )
|
||||
end
|
||||
end
|
||||
|
||||
require 'capybara/webkit'
|
||||
connection = Capybara::Webkit::Connection.new(:socket_class => TCPSocket)
|
||||
$webkit_browser = Capybara::Webkit::Browser.new(connection)
|
||||
|
@ -25,7 +17,7 @@ if ENV['DEBUG']
|
|||
$webkit_browser.enable_logging
|
||||
end
|
||||
|
||||
require File.join(spec_dir, "spec_helper")
|
||||
require 'capybara/spec/spec_helper'
|
||||
|
||||
Capybara.register_driver :reusable_webkit do |app|
|
||||
Capybara::Webkit::Driver.new(app, :browser => $webkit_browser)
|
||||
|
|
Loading…
Reference in a new issue