title: uninitialized constant error in RSpec
body: <p>I'm trying to test my mailer using Capybara and FactoryGirl along with RSpec. I ended up having the error:</p>
  
  <pre><code>/spec/mailers/password_resets_spec.rb:3:in `&lt;top (required)&gt;': uninitialized constant PasswordResets (NameError)
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/configuration.rb:1327:in `block in load_spec_files'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/configuration.rb:1325:in `each'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/configuration.rb:1325:in `load_spec_files'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/runner.rb:102:in `setup'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/runner.rb:88:in `run'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/runner.rb:73:in `run'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/lib/rspec/core/runner.rb:41:in `invoke'
      from /home/alex/.rvm/gems/ruby-2.2.1/gems/rspec-core-3.3.2/exe/rspec:4:in `&lt;top (required)&gt;'
      from /home/alex/.rvm/gems/ruby-2.2.1/bin/rspec:23:in `load'
      from /home/alex/.rvm/gems/ruby-2.2.1/bin/rspec:23:in `&lt;main&gt;'
      from /home/alex/.rvm/gems/ruby-2.2.1/bin/ruby_executable_hooks:15:in `eval'
      from /home/alex/.rvm/gems/ruby-2.2.1/bin/ruby_executable_hooks:15:in `&lt;main&gt;'
  </code></pre>
  
  <p>My PasswordReset resource doesn't contain a model. Maybe it's somehow related with this?</p>
  
  <p><strong>spec/mailers/password_resets_spec.rb</strong></p>
  
  <pre><code>require "spec_helper"
  
  describe PasswordResets do
    it "emails user when requesting password reset" do
      user = FactoryGirl(:user)
      visit login_path
      click_link "Forgot your password?"
      fill_in "Email", with: user.email
      click_button "Reset Password"
    end
  end
  </code></pre>
  
  <p><strong>spec/spec_helper.rb</strong></p>
  
  <pre><code>require 'simplecov'
  SimpleCov.start
  require 'factory_girl_rails'
  require 'capybara/rspec'
  
  RSpec.configure do |config|
    config.expect_with :rspec do |expectations|
      expectations.include_chain_clauses_in_custom_matcher_descriptions = true
    end
  
  
    config.mock_with :rspec do |mocks|
      mocks.verify_partial_doubles = true
    end
  
  
  end
  </code></pre>
  
  <p>What am I doing wrong?</p>