Sha256: c2961f86bb7012efe601f591ccff428215bd78482602e3a8797ecaf1e0edb328

Contents?: true

Size: 521 Bytes

Versions: 41

Compression:

Stored size: 521 Bytes

Contents

require 'spec_helper'

module Ddr::Jobs
  RSpec.describe FixityCheck do

    it "should use the :fixity queue" do
      expect(described_class.queue).to eq(:fixity)
    end

    describe ".perform" do
      let!(:obj) { double(fixity_check: nil) }
      before do
        allow(ActiveFedora::Base).to receive(:find).with("test:1") { obj }
      end
      it "should call `fixity_check` on the object" do
        expect(obj).to receive(:fixity_check)
        described_class.perform("test:1")
      end
    end

  end
end

Version data entries

41 entries across 41 versions & 1 rubygems

Version Path
ddr-models-2.4.8 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.7 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.6 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.5 spec/jobs/fixity_check_spec.rb
ddr-models-3.0.0.beta.10 spec/jobs/fixity_check_spec.rb
ddr-models-3.0.0.beta.9 spec/jobs/fixity_check_spec.rb
ddr-models-3.0.0.beta.8 spec/jobs/fixity_check_spec.rb
ddr-models-3.0.0.beta.7 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.4 spec/jobs/fixity_check_spec.rb
ddr-models-3.0.0.beta.6 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.3 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.2 spec/jobs/fixity_check_spec.rb
ddr-models-3.0.0.beta.4 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.1 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.0 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.0.rc6 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.0.rc5 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.0.rc4 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.0.rc3 spec/jobs/fixity_check_spec.rb
ddr-models-2.4.0.rc2 spec/jobs/fixity_check_spec.rb