Sha256: e83874fd25db15715c22d070cf04f9c84a3d7c2bb2497aabbc557352e503e084

Contents?: true

Size: 517 Bytes

Versions: 6

Compression:

Stored size: 517 Bytes

Contents

require 'spec_helper'

describe Paperclip::Processors::Plain do
  let(:attachment) { double }
  let(:no_deflate) { nil }
  let(:options) { {} }
  let(:file) { test_file }
  subject { Paperclip::Processors::Plain.new(file, options, attachment) }
  before do
    allow(attachment).to receive(:instance_read).with(:no_deflate).and_return(no_deflate)
  end
  describe "#make" do
    it "returns the file" do
      expect(subject.make).not_to be file
      expect(subject.make.read).to eq test_file.read
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
paperclip-deflater-0.1.6 spec/paperclip/processors/plain_spec.rb
paperclip-deflater-0.1.5 spec/paperclip/processors/plain_spec.rb
paperclip-deflater-0.1.4 spec/paperclip/processors/plain_spec.rb
paperclip-deflater-0.1.3 spec/paperclip/processors/plain_spec.rb
paperclip-deflater-0.1.2 spec/paperclip/processors/plain_spec.rb
paperclip-deflater-0.1.1 spec/paperclip/processors/plain_spec.rb