Sha256: 0d2313c9fad091f58a7f7004e8e2042092cfeface357e1835e650ced9a0654ff

Contents?: true

Size: 499 Bytes

Versions: 6

Compression:

Stored size: 499 Bytes

Contents

require 'spec_helper_integration'

module Doorkeeper
  describe ApplicationsController do
    context "when admin is not authenticated" do
      before(:each) do
        Doorkeeper.configuration.stub(:authenticate_admin => proc do
          redirect_to main_app.root_url
        end)
      end

      it "redirects as set in Doorkeeper.authenticate_admin" do
        get :index, :use_route => :doorkeeper
        response.should redirect_to(controller.main_app.root_url)
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
doorkeeper-0.4.2 spec/controllers/applications_controller_spec.rb
doorkeeper-0.4.1 spec/controllers/applications_controller_spec.rb
doorkeeper-0.4.0 spec/controllers/applications_controller_spec.rb
doorkeeper-0.3.4 spec/controllers/applications_controller_spec.rb
doorkeeper-0.3.3 spec/controllers/applications_controller_spec.rb
doorkeeper-0.3.2 spec/controllers/applications_controller_spec.rb