Sha256: 8160b83cb21e8d98b1b13bd94fad80d527a7b979ad50bf6b492cb4d3090f9868
Contents?: true
Size: 916 Bytes
Versions: 6
Compression:
Stored size: 916 Bytes
Contents
require 'test_helper' class SharedPagesHelperTest < ActionView::TestCase include Adminpanel::SharedPagesHelper fixtures :all def test_belong_to_object_name @model = Adminpanel::Salesman #according to fixtures and dummy app relationships assert_equal 'Product saved', belong_to_object_name(adminpanel_salesmen(:one), 'product') @model = nil end def test_pluralize_model assert_equal 'clients', pluralize_model('Adminpanel::Client') end def test_relaitionship_ids assert_equal 'client_ids', relationship_ids('Adminpanel::Client') end def test_class_name_downcase assert_equal 'category', class_name_downcase(Adminpanel::Category.new) end def test_demodulize_class assert_equal 'product', demodulize_class('Adminpanel::Product') end def test_active_tab assert_equal 'active', active_tab(0) assert_equal '', active_tab([*1..15].sample) end end
Version data entries
6 entries across 6 versions & 1 rubygems