/amexsbs/railsapp/vendor/plugins/tab_tab/test/controller_methods_test.rb
https://bitbucket.org/AcireStudios/social-app-demo · Ruby · 25 lines · 19 code · 6 blank · 0 comment · 0 complexity · ccf9ef680a9abb575c295390d886f273 MD5 · raw file
- require File.join(File.dirname(__FILE__), 'test_helper')
- class ControllerMethodsTest < Test::Unit::TestCase
- def test_controller_level_tab
- assert_equal Tab.new(:stuff), StuffController.new.current_tab
- end
- def test_default_controller_level_tab
- assert_equal Tab.new(:bars), BarsController.new.current_tab
- end
- def test_action_level_tab
- assert_equal Tab.new(:stuff => :edit),
- StuffController.new.edit.current_tab
- end
- def test_default_action_level_tab
- assert_equal Tab.new(:stuff), StuffController.new.show.current_tab
- end
- def test_default_controller_and_action_level_tab
- assert_equal Tab.new(:bars), BarsController.new.show.current_tab
- end
- end