Sha256: b1edb3dffca4b2201f9b9132451f99d01f491361c71a43977f67d6f577e184f0
Contents?: true
Size: 622 Bytes
Versions: 66
Compression:
Stored size: 622 Bytes
Contents
require 'spec_helper' require 'cancan/matchers' describe "Ability on embargos and leases" do subject { Ability.new(current_user) } let(:current_user) { create(:user) } describe "a regular user" do it do should_not be_able_to :index, Hydra::AccessControls::Embargo should_not be_able_to :index, Hydra::AccessControls::Lease end end describe "an admin user" do before { allow(current_user).to receive(:groups).and_return(['admin']) } it do should be_able_to :index, Hydra::AccessControls::Embargo should be_able_to :index, Hydra::AccessControls::Lease end end end
Version data entries
66 entries across 66 versions & 1 rubygems