require 'spec_helper'
describe 'devise/mailer/unlock_instructions.html.haml', :type => "view" do
  context "logged in" do
    before(:each) do
#@resource = mock_model(Member)
      @resource = FactoryGirl.create(:member)
      @resource.should_receive(:email).and_return("example@example.com")
      @resource.should_receive(:unlock_token).and_return("fred")
      render
    end

    it "should explain what's happened" do
      rendered.should contain "account has been locked"
    end

    it "should have an unlock link" do
      rendered.should contain "Unlock my account"
    end
  end
end


require 'spec_helper'
describe 'devise/mailer/unlock_instructions.html.haml', :type => "view" do
  context "logged in" do
    before(:each) do
      @resource = FactoryGirl.create(:member)
      render
    end

    it "should explain what's happened" do
      rendered.should contain "account has been locked"
    end

    it "should have an unlock link" do
      rendered.should contain "Unlock my account"
    end
  end
end


Fix broken test for unlock instructions
Fix broken test for unlock instructions

There were some extra assertions left over from Devise's use of mocks that no
longer make sense.
