RSpec And Capybara(Rails5.0)

Rails application comes with a default testing framework known as mini test

But here we discuss RSpec because it is most widely used framework

Installation of Rspec and capybara

Step 1: open Gemfile
add

“gem ‘rspec-rails’, ‘3.1.0’”

in group development, :test do

Step 2: Create another group for test

group :test do
gem ‘capybara’, ‘2.7.1’
end

Step 3: Run

$bundle install

Step 4: Run

$rails generate rspec:install

Step 5: Last Step is to generate Stub

$bundle binstub rspec-core

Great! By this you have successfully installed RSpec

Advertisements

One thought on “RSpec And Capybara(Rails5.0)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s