|
|
@ -25,16 +25,30 @@ RSpec.describe ActivityPub::Activity::Undo do
|
|
|
|
type: 'Announce',
|
|
|
|
type: 'Announce',
|
|
|
|
actor: ActivityPub::TagManager.instance.uri_for(sender),
|
|
|
|
actor: ActivityPub::TagManager.instance.uri_for(sender),
|
|
|
|
object: ActivityPub::TagManager.instance.uri_for(status),
|
|
|
|
object: ActivityPub::TagManager.instance.uri_for(status),
|
|
|
|
|
|
|
|
atomUri: 'barbar',
|
|
|
|
}
|
|
|
|
}
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
before do
|
|
|
|
context do
|
|
|
|
Fabricate(:status, reblog: status, account: sender, uri: 'bar')
|
|
|
|
before do
|
|
|
|
|
|
|
|
Fabricate(:status, reblog: status, account: sender, uri: 'bar')
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
it 'deletes the reblog' do
|
|
|
|
|
|
|
|
subject.perform
|
|
|
|
|
|
|
|
expect(sender.reblogged?(status)).to be false
|
|
|
|
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
it 'deletes the reblog' do
|
|
|
|
context 'with atomUri' do
|
|
|
|
subject.perform
|
|
|
|
before do
|
|
|
|
expect(sender.reblogged?(status)).to be false
|
|
|
|
Fabricate(:status, reblog: status, account: sender, uri: 'barbar')
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
it 'deletes the reblog by atomUri' do
|
|
|
|
|
|
|
|
subject.perform
|
|
|
|
|
|
|
|
expect(sender.reblogged?(status)).to be false
|
|
|
|
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|