ability_test.rb revision be6eb5d7ea1888f2f835fe0fff358f72572afeb4
require 'test_helper'
context 'Ontology' do
setup do
end
context 'owner' do
should 'be allowed: new, create' do
end
end
should 'be allowed: edit, update, destroy, permissions' do
end
end
should 'not be allowed on other: edit, update, destroy, permissions' do
end
end
end
context 'editor' do
should 'be allowed: edit, update' do
end
end
should 'not be allowed: destroy, permissions' do
end
end
end
end
context 'Team' do
setup do
@memberteam.users << @user
end
context 'admin' do
should 'be allowed: edit, update, destroy' do
end
end
end
context 'member' do
should 'be allowed: create, show, index' do
end
end
should 'not be allowed: edit, update, destroy (without admin on team)' do
end
end
should 'not be allowed: edit, update, destroy (without being on team)' do
end
end
end
end
end