Merge branch 'master' into glitch-soc/merge-upstream
No conflicts.
This commit is contained in:
@@ -17,7 +17,7 @@ RSpec.describe TagsController, type: :controller do
|
||||
|
||||
it 'renders application layout' do
|
||||
get :show, params: { id: 'test', max_id: late.id }
|
||||
expect(response).to render_template layout: 'application'
|
||||
expect(response).to render_template layout: 'public'
|
||||
end
|
||||
end
|
||||
|
||||
|
@@ -56,4 +56,22 @@ RSpec.describe UnfollowService, type: :service do
|
||||
expect(a_request(:post, 'http://example.com/inbox')).to have_been_made.once
|
||||
end
|
||||
end
|
||||
|
||||
describe 'remote ActivityPub (reverse)' do
|
||||
let(:bob) { Fabricate(:user, email: 'bob@example.com', account: Fabricate(:account, username: 'bob', protocol: :activitypub, domain: 'example.com', inbox_url: 'http://example.com/inbox')).account }
|
||||
|
||||
before do
|
||||
bob.follow!(sender)
|
||||
stub_request(:post, 'http://example.com/inbox').to_return(status: 200)
|
||||
subject.call(bob, sender)
|
||||
end
|
||||
|
||||
it 'destroys the following relation' do
|
||||
expect(bob.following?(sender)).to be false
|
||||
end
|
||||
|
||||
it 'sends a reject activity' do
|
||||
expect(a_request(:post, 'http://example.com/inbox')).to have_been_made.once
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user