Sha256: ebeaace02ed5a940a3bfd1f6c0871e656930a50bdbd1d76256ce92e3b962c00f

Contents?: true

Size: 884 Bytes

Versions: 82

Compression:

Stored size: 884 Bytes

Contents

RSpec.shared_examples 'a Hyrax::DerivativeService' do
  before do
    raise 'valid_file_set must be set with `let(:valid_file_set)`' unless
      defined? valid_file_set
  end

  subject { described_class.new(file_set) }
  let(:file_set) { valid_file_set }

  it { is_expected.to respond_to(:create_derivatives).with(1).arguments }

  it { is_expected.to respond_to(:cleanup_derivatives).with(0).arguments }

  it { is_expected.to respond_to(:file_set) }

  it { is_expected.to respond_to(:mime_type) }

  it { is_expected.to respond_to(:derivative_url).with(1).arguments }

  describe "#valid?" do
    context "when given a file_set it handles" do
      let(:file_set) { valid_file_set }
      it { is_expected.to be_valid }
    end
  end

  it "takes a fileset as an argument" do
    obj = described_class.new(valid_file_set)
    expect(obj.file_set).to eq valid_file_set
  end
end

Version data entries

82 entries across 82 versions & 1 rubygems

Version Path
hyrax-5.0.1 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-5.0.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-5.0.0.rc3 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-5.0.0.rc2 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-5.0.0.rc1 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.6.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-4.0.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-4.0.0.rc3 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-4.0.0.rc2 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-4.0.0.rc1 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.5.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-4.0.0.beta2 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.4.2 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-4.0.0.beta1 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.4.1 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.4.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.3.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.2.0 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-2.9.6 lib/hyrax/specs/shared_specs/derivative_service.rb
hyrax-3.1.0 lib/hyrax/specs/shared_specs/derivative_service.rb