implement turnip delay for nice view in capybara
This commit is contained in:
@@ -28,6 +28,13 @@ Capybara::Screenshot.webkit_options = { width: 1024, height: 768 }
|
|||||||
WebMock.disable_net_connect!(allow_localhost: true)
|
WebMock.disable_net_connect!(allow_localhost: true)
|
||||||
|
|
||||||
#Capybara.javascript_driver = :selenium
|
#Capybara.javascript_driver = :selenium
|
||||||
|
module TurnipHacks
|
||||||
|
def run_step(*)
|
||||||
|
# delay for a nice follow in selenium
|
||||||
|
#sleep 0.1
|
||||||
|
super
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
module FactoryAttributesFor
|
module FactoryAttributesFor
|
||||||
def attributes_for(obj, options={})
|
def attributes_for(obj, options={})
|
||||||
@@ -88,6 +95,7 @@ RSpec.configure do |config|
|
|||||||
config.include Devise::TestHelpers, type: :controller
|
config.include Devise::TestHelpers, type: :controller
|
||||||
config.include EndWithMatcher
|
config.include EndWithMatcher
|
||||||
config.include Matchers
|
config.include Matchers
|
||||||
|
config.include TurnipHacks, turnip: true
|
||||||
config.include ActiveSupport::Testing::TimeHelpers
|
config.include ActiveSupport::Testing::TimeHelpers
|
||||||
config.include Features::BasicHelpers, type: :feature
|
config.include Features::BasicHelpers, type: :feature
|
||||||
config.include SpecRouteHelpers, type: :feature
|
config.include SpecRouteHelpers, type: :feature
|
||||||
|
|||||||
Reference in New Issue
Block a user