Change ResolveAccountService's handling of skip_webfinger (#15750)
* Change ResolveAccountService's handling of skip_webfinger Change it so it never makes any webfinger query, as the name would imply. * Add tests * Change FollowService to not take an URI for target_account * Restore domain-block check in FollowService * Fix tests
This commit is contained in:
parent
eb83ab45e2
commit
5f4c0b79c2
7 changed files with 60 additions and 19 deletions
|
@ -99,12 +99,10 @@ describe AuthorizeInteractionsController do
|
|||
|
||||
allow(ResolveAccountService).to receive(:new).and_return(service)
|
||||
allow(service).to receive(:call).with('user@hostname').and_return(target_account)
|
||||
allow(service).to receive(:call).with(target_account, skip_webfinger: true).and_return(target_account)
|
||||
|
||||
|
||||
post :create, params: { acct: 'acct:user@hostname' }
|
||||
|
||||
expect(service).to have_received(:call).with(target_account, skip_webfinger: true)
|
||||
expect(account.following?(target_account)).to be true
|
||||
expect(response).to render_template(:success)
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue