Sha256: 2b7750cd1dc7087d74131077d2943d22851306d56480f37725951d0fc0bc4dc2
Contents?: true
Size: 548 Bytes
Versions: 1
Compression:
Stored size: 548 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper') describe WelcomeController do describe "POST /signup (#signup)" do it "should deliver the signup email" do lambda { post :signup, "Email" => "email@example.com", "Name" => "Jimmy Bean" }.should change(ActionMailer::Base.deliveries, :size).by(1) last_delivery = ActionMailer::Base.deliveries.last last_delivery.to.should include "email@example.com" last_delivery.body.to_s.should include "Jimmy Bean" end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
path-email_spec-0.6.2 | examples/rails3_root/spec/controllers/welcome_controller_spec.rb |