fixed merge error

This commit is contained in:
danielvincent 2010-06-15 12:28:21 -07:00
parent a46b0479f4
commit 4da68fc4b1
3 changed files with 6 additions and 8 deletions

View file

@ -3,13 +3,13 @@ require File.dirname(__FILE__) + '/../spec_helper'
describe BookmarksController do
before do
#TODO(dan) Mocking Warden; this is a temp fix
request.env['warden'] = mock_model(Warden, :authenticate => @user, :authenticate! => @user)
@bob = Factory.create(:user)
request.env['warden'] = mock_model(Warden, :authenticate? => @user, :authenticate! => @user)
@bob = Factory.build(:user)
@bookmark = Factory.build(:bookmark)
@bookmark.save #TODO figure out why validations are not working
@bob.save
@bookmark.save
end
render_views
it "index action should render index template" do

View file

@ -4,7 +4,7 @@ describe FriendsController do
render_views
before do
#TODO(dan) Mocking Warden; this is a temp fix
request.env['warden'] = mock_model(Warden, :authenticate => @user, :authenticate! => @user)
request.env['warden'] = mock_model(Warden, :authenticate? => @user, :authenticate! => @user)
@friend = Factory.build(:friend)
end
@ -15,7 +15,6 @@ describe FriendsController do
it "show action should render show template" do
@friend.save
request.env['warden'].should_receive(:authenticate?).at_least(:once)
get :show, :id => @friend.id
response.should render_template(:show)
end

View file

@ -3,7 +3,7 @@ require File.dirname(__FILE__) + '/../spec_helper'
describe StatusMessagesController do
before do
#TODO(dan) Mocking Warden; this is a temp fix
request.env['warden'] = mock_model(Warden, :authenticate => @user, :authenticate! => @user)
request.env['warden'] = mock_model(Warden, :authenticate? => @user, :authenticate! => @user)
@bob = Factory.build(:user,:email => "bob@aol.com", :password => "secret")
@status_message = Factory.build(:status_message, :message => "yodels.")
@bob.save
@ -43,7 +43,6 @@ describe StatusMessagesController do
end
it "show action should render show template" do
request.env['warden'].should_receive(:authenticate?).at_least(:once)
get :show, :id => @status_message.id
response.should render_template(:show)
end