services controller should now go back to the referer. this might not actually work

This commit is contained in:
maxwell 2010-11-08 16:18:15 -08:00
parent 3fd5852d44
commit 52908cec1a
2 changed files with 2 additions and 1 deletions

View file

@ -32,7 +32,7 @@ class ServicesController < ApplicationController
end
flash[:notice] = I18n.t 'services.create.success'
redirect_to services_url
redirect_to :back
end
def destroy

View file

@ -36,6 +36,7 @@ describe ServicesController do
describe '#create' do
it 'creates a new OmniauthService' do
request.env['omniauth.auth'] = omniauth_auth
request.env["HTTP_REFERER"] = ""
lambda{post :create}.should change(user.services, :count).by(1)
end
end