From 85d89b472dff2c3d06801dbd42f91c325d21a434 Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 8 Sep 2016 20:36:01 +0200 Subject: Optimized n+1 queries in accounts Atom and HTML views Added stack trace for SQL queries in development Removed badly thought out accounts/lookup API --- .../api/accounts/lookup_controller_spec.rb | 24 ---------------------- 1 file changed, 24 deletions(-) delete mode 100644 spec/controllers/api/accounts/lookup_controller_spec.rb (limited to 'spec/controllers') diff --git a/spec/controllers/api/accounts/lookup_controller_spec.rb b/spec/controllers/api/accounts/lookup_controller_spec.rb deleted file mode 100644 index 3f590b82f..000000000 --- a/spec/controllers/api/accounts/lookup_controller_spec.rb +++ /dev/null @@ -1,24 +0,0 @@ -require 'rails_helper' - -RSpec.describe Api::Accounts::LookupController, type: :controller do - render_views - - let(:user) { Fabricate(:user, account: Fabricate(:account, username: 'alice')) } - let(:token) { double acceptable?: true, resource_owner_id: user.id } - - before do - allow(controller).to receive(:doorkeeper_token) { token } - end - - describe 'GET #index' do - before do - Fabricate(:account, username: 'bob') - Fabricate(:account, username: 'mcbeth') - get :index, params: { usernames: 'alice,bob,mcbeth' } - end - - it 'returns http success' do - expect(response).to have_http_status(:success) - end - end -end -- cgit