Sha256: 1fca6432a908fca596fd42bc41b360c948abd795ebe49a20ec3e1fb00009f15c
Contents?: true
Size: 743 Bytes
Versions: 10
Compression:
Stored size: 743 Bytes
Contents
require 'spec_helper' describe Paperclip::Processors::DeflaterBase do let(:attachment) { double } let(:no_deflate) { nil } let(:options) { {} } let(:file) { test_file } subject { Paperclip::Processors::DeflaterBase.new(file, options, attachment) } before do allow(attachment).to receive(:instance_read).with(:no_deflate).and_return(no_deflate) end describe "#make" do it "raises an exception" do expect{ subject.make }.to raise_error(NotImplementedError) end end describe "private methods" do describe "create_tempfile" do it "returns a tempfile" do f = subject.send(:create_tempfile) expect(f).to be_a Tempfile expect(f.binmode?).to be true end end end end
Version data entries
10 entries across 10 versions & 1 rubygems