Sha256: 2a0d1b28051a290dd5d32d0b0aba140749614c5c1e22ac282c91c3a48301bdf5
Contents?: true
Size: 842 Bytes
Versions: 16
Compression:
Stored size: 842 Bytes
Contents
require File.dirname(__FILE__) + '/../spec_helper' describe Dragonfly::JobDefinitions do describe "defining jobs" do before(:each) do @job_definitions = Dragonfly::JobDefinitions.new @object = Object.new @object.extend @job_definitions end describe "a simple job" do before(:each) do @job_definitions.add :thumb do |size| process :thumb, size end end it "correctly call job steps" do @object.should_receive(:process).with(:thumb, '30x30#').and_return(job=mock) @object.thumb('30x30#').should == job end it "should correctly call job steps when bang is given" do @object.should_receive(:process!).with(:thumb, '30x30#').and_return(@object) @object.thumb!('30x30#').should == @object end end end end
Version data entries
16 entries across 16 versions & 2 rubygems