spec/omniauth/strategies/dice_integrations_spec.rb in omniauth-dice-0.1.5 vs spec/omniauth/strategies/dice_integrations_spec.rb in omniauth-dice-0.1.6
- old
+ new
@@ -140,21 +140,18 @@
context 'success' do
it 'should return a 200 with a JSON object of user information on success' do
header 'Ssl-Client-Cert', user_cert
get '/auth/dice'
follow_redirect!
- expect(last_response.location).to eq('/')
- ap last_request.env['rack.session']['omniauth.auth'].inspect
raw_info = last_request.env['rack.session']['omniauth.auth']['extra']['raw_info']
expect(raw_info).to eq(valid_user_json)
end
it 'should return an omniauth auth_hash' do
header 'Ssl-Client-Cert', user_cert
get '/auth/dice'
follow_redirect!
- expect(last_response.location).to eq('/')
raw_info = last_request.env['rack.session']['omniauth.auth']['extra']['raw_info']
expect(last_request.env['rack.session']['omniauth.auth']).to be_kind_of(Hash)
expect(last_request.env['rack.session']['omniauth.auth'].sort).to eq(auth_hash.sort)
end
@@ -176,10 +173,9 @@
to_return(status: 200, body: valid_user_xml, headers: {})
header 'Ssl-Client-Cert', user_cert
get '/auth/dice'
follow_redirect!
- expect(last_response.location).to eq('/')
raw_info = last_request.env['rack.session']['omniauth.auth']['extra']['raw_info']
expect(raw_info).to eq(valid_user_xml)
end
end