fixes specs (unauthenticated users can view spending proposal show)

This commit is contained in:
rgarcia
2016-06-20 21:54:45 +02:00
parent 9e910a834b
commit 00dbbd0689
2 changed files with 1 additions and 4 deletions

View File

@@ -1,7 +1,7 @@
class SpendingProposalsController < ApplicationController class SpendingProposalsController < ApplicationController
include FeatureFlags include FeatureFlags
before_action :authenticate_user!, except: [:index] before_action :authenticate_user!, except: [:index, :show]
before_action -> { flash.now[:notice] = flash[:notice].html_safe if flash[:html_safe] && flash[:notice] } before_action -> { flash.now[:notice] = flash[:notice].html_safe if flash[:html_safe] && flash[:notice] }
load_and_authorize_resource load_and_authorize_resource

View File

@@ -178,9 +178,6 @@ feature 'Spending proposals' do
end end
scenario "Show" do scenario "Show" do
user = create(:user)
login_as(user)
spending_proposal = create(:spending_proposal, spending_proposal = create(:spending_proposal,
geozone: create(:geozone), geozone: create(:geozone),
association_name: 'People of the neighbourhood') association_name: 'People of the neighbourhood')