Sha256: 7bfde9ba8ddbed7152dbdb6f23399a1c69e1fad9e622197e054a3e1d359f7154

Contents?: true

Size: 1 KB

Versions: 3

Compression:

Stored size: 1 KB

Contents

# require 'rubygems'
require 'test_helper'

require 'netzke-core'
require 'netzke/border_layout_panel'
require 'netzke/panel'
require 'netzke/properties_tool'
require 'netzke/db_fields'
require 'netzke/grid_panel'

class BorderLayoutPanelTest < ActiveSupport::TestCase
  test "dependencies" do
    widget = Netzke::BorderLayoutPanel.new(:name => 'Bla', :regions => {:center => {:widget_class_name => 'Panel'}, :east => {:widget_class_name => 'GridPanel'}})
    
    assert(%w{BorderLayoutPanel Panel GridPanel}.all?{|k| widget.dependencies.include?(k)})
    
    assert(widget.js_missing_code.index("Ext.netzke.cache['BorderLayoutPanel']"))
    # assert(widget.js_missing_code.index("Ext.netzke.cache['Panel']"))
    assert(!widget.js_missing_code(%w{GridPanel Panel}).index("Ext.netzke.cache['GridPanel']"))
    # assert(!widget.js_missing_code(%w{GridPanel Panel}).index("Ext.netzke.cache['Panel']"))
    # assert(!widget.js_missing_code(%w{BorderLayoutPanel}).index("Ext.netzke.cache['BorderLayoutPanel']"))
    
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
netzke-basepack-0.3.3 test/border_layout_panel_test.rb
netzke-basepack-0.3.3.1 test/border_layout_panel_test.rb
netzke-basepack-0.3.4 test/border_layout_panel_test.rb