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

set rspec type to :feature instead

This commit is contained in:
Jonas Nicklas 2012-09-07 20:17:38 +02:00
parent 7fa75e5542
commit de34c63835
3 changed files with 4 additions and 6 deletions

View file

@ -5,10 +5,8 @@ require 'capybara/rspec/matchers'
require 'capybara/rspec/features'
RSpec.configure do |config|
config.include Capybara::DSL, :type => :request
config.include Capybara::DSL, :type => :acceptance
config.include Capybara::RSpecMatchers, :type => :request
config.include Capybara::RSpecMatchers, :type => :acceptance
config.include Capybara::DSL, :type => :feature
config.include Capybara::RSpecMatchers, :type => :feature
# The before and after blocks must run instantaneously, because Capybara
# might not actually be used in all examples where it's included.
config.after do

View file

@ -12,7 +12,7 @@ end
def self.feature(*args, &block)
options = if args.last.is_a?(Hash) then args.pop else {} end
options[:capybara_feature] = true
options[:type] = :request
options[:type] = :feature
options[:caller] ||= caller
args.push(options)

View file

@ -1,6 +1,6 @@
require 'spec_helper'
describe 'capybara/rspec', :type => :request do
describe 'capybara/rspec', :type => :feature do
it "should include Capybara in rspec" do
visit('/foo')
page.body.should include('Another World')