Sha256: cb5f3e58b4f0f874d3a40900f2e2ff852925a4b886e9db31273110a2e40f629e

Contents?: true

Size: 567 Bytes

Versions: 7

Compression:

Stored size: 567 Bytes

Contents

require "spec_helper"

module GotFixed
  describe UserMailer do
    describe "#subject" do
      it "should evaluate template with issue title" do
        @user_mailer = UserMailer.send :new
        issue = FactoryGirl.build :got_fixed_issue, :title => "Dummy issue"
        old_config = GotFixed.config
        GotFixed.config = {
          :user_mailer => {
            :subject_template => "[Fixed] %{title}"
          }
        }
        @user_mailer.subject(issue).should eq "[Fixed] Dummy issue"
        GotFixed.config = old_config
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
got_fixed-0.1.0 spec/mailers/got_fixed/user_mailer_spec.rb
got_fixed-0.0.6 spec/mailers/got_fixed/user_mailer_spec.rb
got_fixed-0.0.5 spec/mailers/got_fixed/user_mailer_spec.rb
got_fixed-0.0.4 spec/mailers/got_fixed/user_mailer_spec.rb
got_fixed-0.0.3 spec/mailers/got_fixed/user_mailer_spec.rb
got_fixed-0.0.2 spec/mailers/got_fixed/user_mailer_spec.rb
got_fixed-0.0.1 spec/mailers/got_fixed/user_mailer_spec.rb