Allow all users use search method for advisories
This commit is contained in:
parent
0da9bfef74
commit
37f6390910
|
@ -21,7 +21,7 @@ class Ability
|
||||||
can :search, BuildList
|
can :search, BuildList
|
||||||
can [:read, :log, :everything], BuildList, :project => {:visibility => 'open'}
|
can [:read, :log, :everything], BuildList, :project => {:visibility => 'open'}
|
||||||
can [:read, :log], ProductBuildList#, :product => {:platform => {:visibility => 'open'}} # double nested hash don't work
|
can [:read, :log], ProductBuildList#, :product => {:platform => {:visibility => 'open'}} # double nested hash don't work
|
||||||
can :read, Advisory
|
can [:read, :search], Advisory
|
||||||
|
|
||||||
# Platforms block
|
# Platforms block
|
||||||
can [:show, :members, :advisories], Platform, :visibility => 'open'
|
can [:show, :members, :advisories], Platform, :visibility => 'open'
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
# -*- encoding : utf-8 -*-
|
||||||
|
require 'spec_helper'
|
||||||
|
|
||||||
|
describe AdvisoriesController do
|
||||||
|
context 'for all' do
|
||||||
|
it "should be able to perform search action" do
|
||||||
|
get :search
|
||||||
|
response.should_not redirect_to(forbidden_path)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
Loading…
Reference in New Issue