Sha256: 584a646e0f7db8733b26e56d67547f55fcbd23b08849d503b7f69f22482a29ac
Contents?: true
Size: 1.12 KB
Versions: 18
Compression:
Stored size: 1.12 KB
Contents
require "test_helper" class ContentRenderingSupportTest < ActiveSupport::TestCase def setup end def teardown end test "still has error handling methods" do c = Cms::ContentController.new assert c.respond_to? :handle_access_denied_on_page assert c.respond_to? :handle_not_found_on_page assert c.respond_to? :handle_server_error_on_page assert c.respond_to? :handle_error_with_cms_page, true assert(c.respond_to?(:logged_in?), "Should include Cms::Authentication::Controller methods") end class MyController < ActionController::Base include Cms::ContentRenderingSupport end test "Arbitrary controller should have authentication methods" do c = MyController.new assert c.respond_to? :handle_access_denied_on_page assert c.respond_to? :handle_not_found_on_page assert c.respond_to? :handle_server_error_on_page assert c.respond_to? :handle_error_with_cms_page, true assert(!c.respond_to?(:logged_in?), "Should Not include Cms::Authentication::Controller methods") assert(c.respond_to?(:handle_server_error), "Should include Cms::ErrorHandling methods") end end
Version data entries
18 entries across 18 versions & 5 rubygems