Sha256: 44aee22a4f5066d2efeffdb882f31db20d68a2a8dba2841a52669a88dff73783

Contents?: true

Size: 807 Bytes

Versions: 18

Compression:

Stored size: 807 Bytes

Contents

module OmniAuth

  module Test

    module StrategyMacros

      def sets_an_auth_hash
        it 'should set an auth hash' do
          last_request.env['omniauth.auth'].should be_kind_of(Hash)
        end
      end

      def sets_provider_to(provider)
        it "should set the provider to #{provider}" do
          (last_request.env['omniauth.auth'] || {})['provider'].should == provider
        end
      end

      def sets_uid_to(uid)
        it "should set the UID to #{uid}" do
          (last_request.env['omniauth.auth'] || {})['uid'].should == uid
        end
      end

      def sets_user_info_to(user_info)
        it "should set the user_info to #{user_info}" do
          (last_request.env['omniauth.auth'] || {})['user_info'].should == user_info
        end
      end
    end

  end

end

Version data entries

18 entries across 18 versions & 2 rubygems

Version Path
omniauth-1.1.1 lib/omniauth/test/strategy_macros.rb
omniauth-1.1.0 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.3 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.2 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.1 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.0 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.0.rc2 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.0.rc1 lib/omniauth/test/strategy_macros.rb
oa-core-0.3.2 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.0.beta1 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.0.pr2 lib/omniauth/test/strategy_macros.rb
omniauth-1.0.0.pr1 lib/omniauth/test/strategy_macros.rb
oa-core-0.3.0 lib/omniauth/test/strategy_macros.rb
oa-core-0.3.0.rc3 lib/omniauth/test/strategy_macros.rb
omniauth-0.2.6 oa-core/lib/omniauth/test/strategy_macros.rb
oa-core-0.2.6 lib/omniauth/test/strategy_macros.rb
omniauth-0.2.5 oa-core/lib/omniauth/test/strategy_macros.rb
oa-core-0.2.5 lib/omniauth/test/strategy_macros.rb