IZ DG MS; fix method call in public receiver
This commit is contained in:
parent
2bb2c6e3e8
commit
999efbd451
4 changed files with 12 additions and 4 deletions
|
|
@ -5,6 +5,7 @@
|
|||
class PublicsController < ApplicationController
|
||||
require File.join(Rails.root, '/lib/diaspora/parser')
|
||||
require File.join(Rails.root, '/lib/postzord/receiver/public')
|
||||
require File.join(Rails.root, '/lib/postzord/receiver/private')
|
||||
include Diaspora::Parser
|
||||
|
||||
skip_before_filter :set_header_data
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
# Copyright (c) 2010-2011, Diaspora Inc. This file is
|
||||
# licensed under the Affero General Public License version 3 or later. See
|
||||
# the COPYRIGHT file.
|
||||
require File.join(Rails.root, 'lib/postzord/receiver/private')
|
||||
|
||||
require File.join(Rails.root, 'lib/postzord/receiver/public')
|
||||
|
||||
module Jobs
|
||||
class ReceiveUnencryptedSalmon < Base
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Copyright (c) 2010-2011, Diaspora Inc. This file is
|
||||
# licensed under the Affero General Public License version 3 or later. See
|
||||
# the COPYRIGHT file.
|
||||
#
|
||||
|
||||
module Postzord
|
||||
module Receiver
|
||||
class Public
|
||||
|
|
@ -25,7 +25,7 @@ module Postzord
|
|||
if @object.respond_to?(:relayable?)
|
||||
receive_relayable
|
||||
else
|
||||
Resque.enqueue(Jobs::ReceiveLocalBatch, @object.id, self.recipient_user_ids)
|
||||
Resque.enqueue(Jobs::ReceiveLocalBatch, @object.class.to_s, @object.id, self.recipient_user_ids)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -56,9 +56,15 @@ describe Postzord::Receiver::Public do
|
|||
end
|
||||
|
||||
it 'enqueues a Jobs::ReceiveLocalBatch' do
|
||||
Resque.should_receive(:enqueue).with(Jobs::ReceiveLocalBatch, anything, anything)
|
||||
Resque.should_receive(:enqueue).with(Jobs::ReceiveLocalBatch, anything, anything, anything)
|
||||
@receiver.perform!
|
||||
end
|
||||
|
||||
it 'intergrates' do
|
||||
fantasy_resque do
|
||||
@receiver.perform!
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue