README.md in email_spec-2.1.1 vs README.md in email_spec-2.1.2

- old
+ new

@@ -47,22 +47,28 @@ ```gherkin Scenario: A new person signs up Given I am at "/" When I fill in "Email" with "quentin@example.com" And I press "Sign up" - And "quentin@example.com" should receive an email # Specify who should receive the email + Then "quentin@example.com" should receive an email # Specify who should receive the email ``` ### RSpec (3.1+) -First you need to require email_spec in your spec_helper.rb: +First you need to require `email_spec` in your `spec_helper.rb`: ```ruby require "email_spec" require "email_spec/rspec" ``` This will load all the helpers that the scenarios can count on. It will also add a `before(:each)` hook so that emails are cleared at the start of each scenario. + +If you are upgrading to Rails 5, make sure your `rails_helper.rb` requires `spec_helper` **after** loading the environment. For example: +```ruby +require File.expand_path('../../config/environment', __FILE__) +require 'spec_helper' +``` ### MiniTest First you need to require minitest-matchers and email_spec in your test_helper.rb: