2023-02-21 18:55:31 -06:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2017-08-12 17:44:41 -05:00
|
|
|
require 'rails_helper'
|
|
|
|
|
|
|
|
describe ActivityPub::ProcessingWorker do
|
|
|
|
subject { described_class.new }
|
|
|
|
|
|
|
|
let(:account) { Fabricate(:account) }
|
|
|
|
|
|
|
|
describe '#perform' do
|
|
|
|
it 'delegates to ActivityPub::ProcessCollectionService' do
|
2023-06-22 07:55:22 -05:00
|
|
|
allow(ActivityPub::ProcessCollectionService).to receive(:new)
|
|
|
|
.and_return(instance_double(ActivityPub::ProcessCollectionService, call: nil))
|
2017-08-12 17:44:41 -05:00
|
|
|
subject.perform(account.id, '')
|
|
|
|
expect(ActivityPub::ProcessCollectionService).to have_received(:new)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|