title: RSpec 3.6 and Rails 5.0.1 - ArgumentError: wrong number of arguments (given 0, expected 1)
body: <p>I'm trying to write a mailer test using RSpec. However, it is failing and I cannot figure out why. My failure notification is the following:</p>
  
  <pre><code>Failures:
  
    1) UserMailer welcome_email sends an email upon new user registration
       Failure/Error:
         def welcome_email(id)
           @user = User.find(id)
           mail(to: @user.email, subject: 'Welcome on board!')
         end
  
       ArgumentError:
         wrong number of arguments (given 0, expected 1)
       # ./app/mailers/user_mailer.rb:4:in `welcome_email'
       # ./spec/mailers/user_mailer_spec.rb:10:in `block (3 levels) in &lt;top (required)&gt;'
  </code></pre>
  
  <p>The relevant code in the file I'm testing is the following:</p>
  
  <pre><code>class UserMailer &lt; ApplicationMailer
    default from: 'noreply@example.com'
  
    def welcome_email(id)
      @user = User.find(id)
      mail(to: @user.email, subject: 'Welcome on board!')
    end
  end
  </code></pre>
  
  <p>And this is my spec:</p>
  
  <pre><code>require "rails_helper"
  
  
  RSpec.describe UserMailer, :type =&gt; :mailer do
    describe "welcome_email" do
      let(:mail) { UserMailer.welcome_email }
  
      it 'sends an email upon new user registration' do
        expect(mail.subject).to eq('Welcome on board!')
      end   
    end
  end
  </code></pre>
  
  <p>I have tried all suggestions for this error I could find elsewhere to no avail. What am I doing wrong?</p>