Sha256: e0360c04efbba361eec1edaa480de027173ad589fb3c7ddc6e42227f26d4a926

Contents?: true

Size: 628 Bytes

Versions: 1

Compression:

Stored size: 628 Bytes

Contents

require 'test_helper'
require 'rubygems'
require 'netzke-core'

class AccordionPanelTest < ActiveSupport::TestCase
  
  test "specifying items" do
    accordion = Netzke::AccordionPanel.new(:items => [{
      :class_name => "Panel"
    },{
      :class_name => "Panel", :name => "second_panel", :active => true
    }])
        
    assert_equal(2, accordion.initial_components.keys.size)
    assert_equal("item0", accordion.components[:item0][:name])
    assert_equal("second_panel", accordion.components[:second_panel][:name])
    assert_equal("Panel", accordion.js_config[:second_panel_config][:scoped_class_name])
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
netzke-basepack-0.6.0 test/unit/accordion_panel_test.rb