From 092fdc89fa5b2a1ba2ac0a0dfe5149814a179ec8 Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Mon, 24 Apr 2017 11:30:30 -0400 Subject: Fix flashes partial render error for controllers which don't inherit from application controller (#2400) * Add failing spec for oauth/authorized_applications controller * Use explicit reference to flashes partial from admin layout Because some of the controllers which use the admin layout do not inherit from application controller, this partial is not in their view path. --- .../authorized_applications_controller_spec.rb | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 spec/controllers/oauth/authorized_applications_controller_spec.rb (limited to 'spec/controllers/oauth') diff --git a/spec/controllers/oauth/authorized_applications_controller_spec.rb b/spec/controllers/oauth/authorized_applications_controller_spec.rb new file mode 100644 index 000000000..f5d64bd90 --- /dev/null +++ b/spec/controllers/oauth/authorized_applications_controller_spec.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe Oauth::AuthorizedApplicationsController do + render_views + + before do + sign_in Fabricate(:user), scope: :user + end + + describe 'GET #index' do + before do + get :index + end + + it 'returns http success' do + expect(response).to have_http_status(:success) + end + end +end -- cgit