Sha256: e60b6a5ba445ff633aed614f6b18c8e0536ce3fb0f59d51cdbc7041fb592eab4

Contents?: true

Size: 473 Bytes

Versions: 8

Compression:

Stored size: 473 Bytes

Contents

require 'spec_helper'

describe MetaPresenter::Base do

  describe '#inspect' do
    subject { presenter.inspect }

    let(:controller_class) { ApplicationController }
    let(:controller) { controller_class.new }
    let(:action_name) { 'test' }
    let(:presenter) { controller.view_context.presenter }
    
    before do
      allow(controller).to receive(:action_name).and_return(action_name)
    end

    it { is_expected.to eql('#<ApplicationPresenter>') }
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
meta_presenter-2.0.0 spec/meta_presenter/base_spec.rb
meta_presenter-1.0.1 spec/meta_presenter/base_spec.rb
meta_presenter-1.0.0 spec/meta_presenter/base_spec.rb
meta_presenter-0.2.4 spec/meta_presenter/base_spec.rb
meta_presenter-0.2.3 spec/meta_presenter/base_spec.rb
meta_presenter-0.2.2 spec/meta_presenter/base_spec.rb
meta_presenter-0.2.1 spec/meta_presenter/base_spec.rb
meta_presenter-0.2.0 spec/meta_presenter/base_spec.rb