Sha256: 80795bc7ddc9828af399696d2fa2d9535867683fc4b3f0d5c10f9be29b13ed22

Contents?: true

Size: 593 Bytes

Versions: 7

Compression:

Stored size: 593 Bytes

Contents

# frozen_string_literal: true

require 'support/models/authorizy_cop'

RSpec.describe AuthorizyCop do
  let!(:params) { { controller: 'controller', action: 'action' } }
  let(:cop) { described_class.new('current_user', params, 'session') }

  it 'adds private attributes readers' do
    expect(cop.fetch_action).to       eq('action')
    expect(cop.fetch_controller).to   eq('controller')
    expect(cop.fetch_current_user).to eq('current_user')
    expect(cop.fetch_params).to       eq(controller: 'controller', action: 'action')
    expect(cop.fetch_session).to      eq('session')
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
authorizy-0.5.0 spec/authorizy/cop/model_spec.rb
authorizy-0.4.1 spec/authorizy/cop/model_spec.rb
authorizy-0.4.0 spec/authorizy/cop/model_spec.rb
authorizy-0.3.0 spec/authorizy/cop/model_spec.rb
authorizy-0.2.2 spec/authorizy/cop/model_spec.rb
authorizy-0.2.1 spec/authorizy/cop/model_spec.rb
authorizy-0.2.0 spec/authorizy/cop/model_spec.rb