Sha256: 244776644e2e7f0a9664409193dc8ee44bc26b42bfc86fa827b27565abeabdfb
Contents?: true
Size: 844 Bytes
Versions: 9
Compression:
Stored size: 844 Bytes
Contents
require 'test_helper' class Custom::OmniauthCallbacksControllerTest < ActionDispatch::IntegrationTest describe Custom::OmniauthCallbacksController do setup do OmniAuth.config.test_mode = true OmniAuth.config.mock_auth[:facebook] = OmniAuth::AuthHash.new({ :provider => 'facebook', :uid => '123545', :info => { name: 'swong', email: 'swongsong@yandex.ru' } }) end test "yield resource to block on omniauth_sucess success" do @redirect_url = "http://ng-token-auth.dev/" get_via_redirect '/nice_user_auth/facebook', { auth_origin_url: @redirect_url, omniauth_window_type: 'newWindow' } assert @controller.omniauth_success_block_called?, "omniauth_success failed to yield resource to provided block" end end end
Version data entries
9 entries across 9 versions & 1 rubygems