Sha256: 33cdd77e8f23f293feb0a26cb3b3a4f7f21193ac614c7988488bd956855f76a5

Contents?: true

Size: 530 Bytes

Versions: 13

Compression:

Stored size: 530 Bytes

Contents

require 'spec_helper'

describe Sufia::GenericFile, :type => :model do
  module VisibilityOverride
    extend ActiveSupport::Concern
    include Sufia::GenericFile::Permissions
    def visibility; super; end
    def visibility=(value); super(value); end
  end
  class MockParent < ActiveFedora::Base
    include VisibilityOverride
  end

  it 'allows for overrides of visibility' do
    expect{
      MockParent.new(visibility: Hydra::AccessControls::AccessRight::VISIBILITY_TEXT_VALUE_PRIVATE)
    }.to_not raise_error
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
sufia-6.2.0 spec/models/generic_file/visibility_spec.rb
sufia-6.1.0 spec/models/generic_file/visibility_spec.rb
sufia-5.0.0 spec/models/generic_file/visibility_spec.rb
sufia-6.0.0 spec/models/generic_file/visibility_spec.rb
sufia-6.0.0.rc4 spec/models/generic_file/visibility_spec.rb
sufia-6.0.0.rc3 spec/models/generic_file/visibility_spec.rb
sufia-5.0.0.rc1 spec/models/generic_file/visibility_spec.rb
sufia-6.0.0.rc2 spec/models/generic_file/visibility_spec.rb
sufia-6.0.0.rc1 spec/models/generic_file/visibility_spec.rb
sufia-4.3.1 spec/models/generic_file/visibility_spec.rb
sufia-6.0.0.beta1 spec/models/generic_file/visibility_spec.rb
sufia-4.2.0 spec/models/generic_file/visibility_spec.rb
sufia-4.1.0 spec/models/generic_file/visibility_spec.rb