Commit f9e8687db3e0ff296cdf1be75ed9e4561402f8a1

Authored by Thiago Ribeiro
1 parent d9ca4b50

FIrst test passed, test new rack app.

lib/omniauth/remote_user.rb
1 require 'omniauth' 1 require 'omniauth'
2 2
3 -module Omniauth 3 +module OmniAuth
4 module Strategies 4 module Strategies
5 autoload :RemoteUser, 'omniauth/strategies/remote_user' 5 autoload :RemoteUser, 'omniauth/strategies/remote_user'
6 end 6 end
spec/omniauth/strategies/remote_user_spec.rb
@@ -4,7 +4,7 @@ describe 'Test Strategy Remote_User' do @@ -4,7 +4,7 @@ describe 'Test Strategy Remote_User' do
4 let(:app) do 4 let(:app) do
5 Rack::Builder.new do |b| 5 Rack::Builder.new do |b|
6 b.use Rack::Session::Cookie, :secret => 'abc123' 6 b.use Rack::Session::Cookie, :secret => 'abc123'
7 - b.use OmniAuth::Strategies::RemoteUser#, :fields => [:name, :email], :uid_field => :name 7 + b.use OmniAuth::Strategies::RemoteUser, :fields => [:name, :email], :uid_field => :name
8 b.run lambda { |_env| [200, {}, ['Not Found']] } 8 b.run lambda { |_env| [200, {}, ['Not Found']] }
9 end.to_app 9 end.to_app
10 end 10 end