From 613e7c7521252bd85e473d9c63cbc8b8e1a733a8 Mon Sep 17 00:00:00 2001 From: Akihiko Odaki Date: Mon, 22 Jan 2018 22:25:09 +0900 Subject: Rename ResolveRemoteAccountService to ResolveAccountService (#6327) The service used to be named ResolveRemoteAccountService resolves local accounts as well. --- spec/controllers/authorize_follows_controller_spec.rb | 4 ++-- spec/controllers/settings/imports_controller_spec.rb | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'spec/controllers') diff --git a/spec/controllers/authorize_follows_controller_spec.rb b/spec/controllers/authorize_follows_controller_spec.rb index 26e46a23c..b1cbef7ea 100644 --- a/spec/controllers/authorize_follows_controller_spec.rb +++ b/spec/controllers/authorize_follows_controller_spec.rb @@ -30,7 +30,7 @@ describe AuthorizeFollowsController do it 'renders error when account cant be found' do service = double - allow(ResolveRemoteAccountService).to receive(:new).and_return(service) + allow(ResolveAccountService).to receive(:new).and_return(service) allow(service).to receive(:call).with('missing@hostname').and_return(nil) get :show, params: { acct: 'acct:missing@hostname' } @@ -54,7 +54,7 @@ describe AuthorizeFollowsController do it 'sets account from acct uri' do account = Account.new service = double - allow(ResolveRemoteAccountService).to receive(:new).and_return(service) + allow(ResolveAccountService).to receive(:new).and_return(service) allow(service).to receive(:call).with('found@hostname').and_return(account) get :show, params: { acct: 'acct:found@hostname' } diff --git a/spec/controllers/settings/imports_controller_spec.rb b/spec/controllers/settings/imports_controller_spec.rb index 4810be701..59b10e0da 100644 --- a/spec/controllers/settings/imports_controller_spec.rb +++ b/spec/controllers/settings/imports_controller_spec.rb @@ -17,7 +17,7 @@ RSpec.describe Settings::ImportsController, type: :controller do describe 'POST #create' do it 'redirects to settings path with successful following import' do service = double(call: nil) - allow(ResolveRemoteAccountService).to receive(:new).and_return(service) + allow(ResolveAccountService).to receive(:new).and_return(service) post :create, params: { import: { type: 'following', @@ -30,7 +30,7 @@ RSpec.describe Settings::ImportsController, type: :controller do it 'redirects to settings path with successful blocking import' do service = double(call: nil) - allow(ResolveRemoteAccountService).to receive(:new).and_return(service) + allow(ResolveAccountService).to receive(:new).and_return(service) post :create, params: { import: { type: 'blocking', -- cgit