Sha256: 386bd48767ee0ca6e42b4dad32099345796ed6a88a0e1233784d7fdeea0d059d

Contents?: true

Size: 538 Bytes

Versions: 8

Compression:

Stored size: 538 Bytes

Contents

require 'test_helper'

class ApiController < ActionController::Metal
  include Devise::Controllers::Helpers
end

class HelperMethodsTest < ActionController::TestCase
  tests ApiController

  test 'includes Devise::Controllers::Helpers' do
    assert_includes @controller.class.ancestors, Devise::Controllers::Helpers
  end

  test 'does not respond_to helper_method' do
    refute_respond_to @controller.class, :helper_method
  end

  test 'defines methods like current_user' do
    assert_respond_to @controller, :current_user
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
devise-3.5.10 test/controllers/helper_methods_test.rb
devise-3.5.9 test/controllers/helper_methods_test.rb
devise-3.5.8 test/controllers/helper_methods_test.rb
devise-3.5.7 test/controllers/helper_methods_test.rb
devise-3.5.6 test/controllers/helper_methods_test.rb
devise-3.5.5 test/controllers/helper_methods_test.rb
devise-3.5.4 test/controllers/helper_methods_test.rb
devise-3.5.3 test/controllers/helper_methods_test.rb