Sha256: 4d68807fecda7a4465667f3a7e008e984f1e5d6c62bd627b374edc7742ab6ecc

Contents?: true

Size: 576 Bytes

Versions: 83

Compression:

Stored size: 576 Bytes

Contents

require 'spec_helper'

describe Tenon::ItemAssetsController do
  routes { Tenon::Engine.routes }

  let(:user) do
    double(
      :staff? => true,
      :is_super_admin? => false,
      :is_admin? => true
    )
  end

  before do
    controller.stub(:current_user) { user }
  end

  describe 'GET new' do
    it 'should assign @multiple to params[:multiple]' do
      get :new, multiple: '1'
      expect(assigns[:multiple]).to eq('1')
    end

    it 'should not render a layout' do
      get :new
      expect(response).to render_template(layout: false)
    end
  end
end

Version data entries

83 entries across 83 versions & 1 rubygems

Version Path
tenon-1.0.64 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.63 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.62 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.61 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.60 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.59 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.57 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.56 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.55 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.54 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.53 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.52 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.51 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.50 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.49 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.48 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.47 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.46 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.45 spec/controllers/tenon/item_assets_controller_spec.rb
tenon-1.0.44 spec/controllers/tenon/item_assets_controller_spec.rb