Sha256: 3c268f2dd7bdb5ac3250d44d671688472b11745460c756b17b03176387fa666f

Contents?: true

Size: 759 Bytes

Versions: 2

Compression:

Stored size: 759 Bytes

Contents

require 'rails_helper'

def it_should_have_view(key, value)
  it "should have #{value} for view key '#{key}'" do
    expect(subject.send(key)).to  eq value
  end
end

RSpec.describe ActiveAdmin::ViewFactory do

  it_should_have_view :global_navigation,    ActiveAdmin::Views::TabbedNavigation
  it_should_have_view :utility_navigation,   ActiveAdmin::Views::TabbedNavigation
  it_should_have_view :site_title,           ActiveAdmin::Views::SiteTitle
  it_should_have_view :action_items,         ActiveAdmin::Views::ActionItems
  it_should_have_view :header,               ActiveAdmin::Views::Header
  it_should_have_view :blank_slate,          ActiveAdmin::Views::BlankSlate
  it_should_have_view :layout,               ActiveAdmin::Views::Pages::Layout

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
activeadmin-1.0.0 spec/unit/view_factory_spec.rb
activeadmin-1.0.0.pre5 spec/unit/view_factory_spec.rb