Sha256: 523b1c2110e429242f1ac62d67880a6903a512dbe9151af948d3e656e885cab6
Contents?: true
Size: 1 KB
Versions: 50
Compression:
Stored size: 1 KB
Contents
require 'spec_helper' describe ActiveAdmin::Views::Panel do let(:the_panel) do render_arbre_component do panel "My Title" do span("Hello World") end end end it "should have a title h3" do the_panel.find_by_tag("h3").first.content.should == "My Title" end it "should have a contents div" do the_panel.find_by_tag("div").first.class_list.should include("panel_contents") end it "should add children to the contents div" do the_panel.find_by_tag("span").first.parent.should == the_panel.find_by_tag("div").first end it "should set the icon" do the_panel = render_arbre_component do panel("Title", :icon => :arrow_down) end the_panel.find_by_tag("h3").first.content.should include("span class=\"icon") end describe "#children?" do it "returns false if no children have been added to the panel" do the_panel = render_arbre_component do panel("A Panel") end the_panel.children?.should == false end end end
Version data entries
50 entries across 50 versions & 2 rubygems