fix the build; don't test on enqueueing a job to fetch facebook friends every time we hit the facebook finder -- only do this on log in
This commit is contained in:
parent
cd7640a971
commit
c5fbe1584a
2 changed files with 0 additions and 8 deletions
|
|
@ -71,8 +71,6 @@ class Services::Facebook < Service
|
||||||
if self.service_users.blank?
|
if self.service_users.blank?
|
||||||
self.save_friends
|
self.save_friends
|
||||||
self.service_users.reload
|
self.service_users.reload
|
||||||
else
|
|
||||||
#Resque.enqueue(Job::UpdateServiceUsers, self.id)
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -90,12 +90,6 @@ JSON
|
||||||
@service.should_receive(:save_friends)
|
@service.should_receive(:save_friends)
|
||||||
@service.finder
|
@service.finder
|
||||||
end
|
end
|
||||||
it 'dispatches a resque job' do
|
|
||||||
Resque.should_receive(:enqueue).with(Job::UpdateServiceUsers, @service.id)
|
|
||||||
su2 = ServiceUser.create(:service => @user2_service, :uid => @user2_fb_id, :name => @user2_fb_name, :photo_url => @user2_fb_photo_url)
|
|
||||||
@service.service_users = [su2]
|
|
||||||
@service.finder
|
|
||||||
end
|
|
||||||
context 'opts' do
|
context 'opts' do
|
||||||
it 'only local does not return people who are remote' do
|
it 'only local does not return people who are remote' do
|
||||||
@service.save_friends
|
@service.save_friends
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue