Removes 'manage' from admin permissions in Polls

This commit is contained in:
kikito
2017-01-29 22:25:10 +01:00
parent 8dc188e4cd
commit 5d13bdc15d
3 changed files with 4 additions and 6 deletions

View File

@@ -53,8 +53,8 @@ module Abilities
can [:index, :create, :edit, :update, :destroy], Geozone
can [:manage], Poll
can [:manage], Poll::Booth
can [:read, :create, :update, :destroy, :add_question, :remove_question, :search_booths, :search_questions, :search_officers], Poll
can [:read, :create, :update, :destroy], Poll::Booth
can [:search, :create, :index, :destroy], ::Poll::Officer
can [:create, :destroy], ::Poll::BoothAssignment
can [:create, :destroy], ::Poll::OfficerAssignment

View File

@@ -20,6 +20,7 @@ feature 'Admin booths assignments' do
fill_in 'search-booths', with: booth.name
click_button 'Search'
expect(page).to have_content(booth.name)
within('#search-booths-results') do
click_link 'Assign booth'
@@ -167,4 +168,4 @@ feature 'Admin booths assignments' do
end
end
end
end

View File

@@ -57,9 +57,6 @@ describe "Abilities::Administrator" do
it { should be_able_to(:valuate, SpendingProposal) }
it { should be_able_to(:destroy, SpendingProposal) }
it { should be_able_to(:manage, Poll) }
it { should be_able_to(:manage, Poll::Booth) }
it { should be_able_to(:create, Budget) }
it { should be_able_to(:update, Budget) }