Merge remote-tracking branch 'parent/main' into upstream-20240115

This commit is contained in:
KMY 2024-01-15 11:08:37 +09:00
commit 673e09d645
338 changed files with 1095 additions and 540 deletions

View file

@ -169,4 +169,22 @@ RSpec.describe RemoveStatusService, :sidekiq_inline, type: :service do
)).to have_been_made.once
end
end
context 'when removed status is a reblog of a non-follower' do
let!(:original_status) { Fabricate(:status, account: bill, text: 'Hello ThisIsASecret', visibility: :public) }
let!(:status) { ReblogService.new.call(alice, original_status) }
it 'sends Undo activity to followers' do
subject.call(status)
expect(a_request(:post, bill.inbox_url).with(
body: hash_including({
'type' => 'Undo',
'object' => hash_including({
'type' => 'Announce',
'object' => ActivityPub::TagManager.instance.uri_for(original_status),
}),
})
)).to have_been_made.once
end
end
end