Make sure Delete reaches collection owner (#38399)

This commit is contained in:
David Roetzel
2026-03-25 16:28:20 +01:00
committed by GitHub
parent e3dfb7ddd6
commit 2a4b205c75
2 changed files with 6 additions and 2 deletions

View File

@@ -13,12 +13,14 @@ RSpec.describe RevokeCollectionItemService do
end
context 'when the collection is remote', feature: :collections_federation do
let(:collection) { Fabricate(:remote_collection) }
let(:account) { Fabricate(:remote_account, inbox_url: 'https://example.com/actor/1/inbox') }
let(:collection) { Fabricate(:remote_collection, account:) }
let(:collection_item) { Fabricate(:collection_item, collection:, uri: 'https://example.com') }
it 'federates a `Delete` activity' do
subject.call(collection_item)
expect(ActivityPub::DeliveryWorker).to have_enqueued_sidekiq_job.with(instance_of(String), collection_item.account_id, 'https://example.com/actor/1/inbox')
expect(ActivityPub::AccountRawDistributionWorker).to have_enqueued_sidekiq_job
end
end