Sha256: c0d2cd453d9791f2e5c2eb9f2265bb47e627c14d513d267043d6aa291d622f88

Contents?: true

Size: 492 Bytes

Versions: 18

Compression:

Stored size: 492 Bytes

Contents

# frozen_string_literal: true

require 'rails_helper'

RSpec.describe 'error path' do
  context 'when there is an error at the oauth server' do
    before do
      stub_g5_invalid_credentials
    end

    it 'should redirect to the error path' do
      visit(protected_page_path)
      expect(current_path).to eq('/g5_auth/auth_error')
    end

    it 'should not use the application layout' do
      visit(protected_page_path)
      expect(page).to_not have_title('Dummy')
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
g5_authenticatable-1.1.4 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.4.rc.3 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.4.rc.2 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.4.rc.1 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2.pre.1 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2.rc.5 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2.rc.4 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2.rc.3 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2.rc.2 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.2.rc.1 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.1 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.1.0 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.0.0 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.0.0.pre.4 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.0.0.pre.3 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.0.0.pre.2 spec/features/auth_error_path_spec.rb
g5_authenticatable-1.0.0.pre.1 spec/features/auth_error_path_spec.rb