<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -13,6 +13,7 @@ require &quot;paperclip/uploaded_file&quot;
 require &quot;paperclip/validations&quot;
 
 require &quot;paperclip/geometry&quot;
+require &quot;paperclip/processor/thumbnail&quot;
 
 module Paperclip
   VERSION = &quot;3.0.0&quot;</diff>
      <filename>lib/paperclip.rb</filename>
    </modified>
    <modified>
      <diff>@@ -30,8 +30,7 @@ module Paperclip
         processors = style_options.delete(:processors)
 
         files[style] = processors.inject(original_file) do |file, name|
-          processor = Processor.for(name)
-          processor.make(file, style_options, self)
+          Processor.for(name).make(file, style_options, self)
         end
         files
       end </diff>
      <filename>lib/paperclip/attachment.rb</filename>
    </modified>
    <modified>
      <diff>@@ -4,7 +4,7 @@ module Paperclip
 
   class Processor
     def self.for(processor_name)
-      Paperclip::Processor.const_get(constantize(processor_name)).new
+      Paperclip::Processor.const_get(constantize(processor_name))
     rescue NameError =&gt; e
       raise Paperclip::ProcessorNotFound.new(e.message)
     end
@@ -13,11 +13,22 @@ module Paperclip
       string.to_s.gsub(%r{(?:^|_)[a-z]}){|m| m[-1..-1].upcase }
     end
 
-    def make(file, options, attachment = nil)
-      file
+    def self.make(file, options, attachment = nil)
+      new(file, options, attachment).make
+    end
+
+    attr_accessor :file, :options, :attachment
+
+    def initialize(file, options, attachment = nil)
+      @file = file
+      @options = options
+      @attachment = attachment
     end
 
-    class Null &lt; Processor
+    def make
+      file
     end
+
+    class Null &lt; Processor; end
   end
 end</diff>
      <filename>lib/paperclip/processor.rb</filename>
    </modified>
    <modified>
      <diff>@@ -87,7 +87,7 @@ def fake_storage
 end
 
 def fake_processor(file = nil)
-  processor = Paperclip::Processor::Null.new
+  processor = stub
   processor.stubs(:make).returns(file)
   processor
 end</diff>
      <filename>test/helper.rb</filename>
    </modified>
    <modified>
      <diff>@@ -209,15 +209,15 @@ class AttachmentTest &lt; Test::Unit::TestCase
     end
 
     should &quot;attempt to call the Thumbnail processor with :normal's parameters&quot; do
-      assert_received(@thumbnail_processor, :make){|s| s.with(@file, {:geometry =&gt; &quot;400x400&quot;, :watermark =&gt; @watermark_file}, @avatar) }
+      assert_received(@thumbnail_processor, :make){|s| s.with(@file, {:geometry =&gt; &quot;400x400&quot;, :watermark =&gt; @watermark_file}, @avatar).once }
     end
 
     should &quot;attempt to call the Thumbnail processor with :thumb's parameters&quot; do
-      assert_received(@thumbnail_processor, :make){|s| s.with(@file, {:geometry =&gt; &quot;32x32&quot;}, @avatar) }
+      assert_received(@thumbnail_processor, :make){|s| s.with(@file, {:geometry =&gt; &quot;32x32&quot;}, @avatar).once }
     end
 
     should &quot;attempt to call the Watermark processor with :normal's parameters&quot; do
-      assert_received(@watermark_processor, :make){|s| s.with(@file, {:geometry =&gt; &quot;400x400&quot;, :watermark =&gt; @watermark_file}, @avatar) }
+      assert_received(@watermark_processor, :make){|s| s.with(@file, {:geometry =&gt; &quot;400x400&quot;, :watermark =&gt; @watermark_file}, @avatar).once }
     end
   end
 </diff>
      <filename>test/unit/attachment_test.rb</filename>
    </modified>
    <modified>
      <diff>@@ -8,15 +8,34 @@ class ProcessorTest &lt; Test::Unit::TestCase
   should &quot;provide a targetted Processor subclass with Processor.for&quot; do
     class Paperclip::Processor; class DummyProcessor &lt; Paperclip::Processor; end; end
     processor = Paperclip::Processor.for(:dummy_processor)
-    assert_equal Paperclip::Processor::DummyProcessor, processor.class
-    assert processor.class.ancestors.include?(Paperclip::Processor)
+    assert_equal Paperclip::Processor::DummyProcessor, processor
+    assert processor.ancestors.include?(Paperclip::Processor)
   end
 
   should &quot;raise a Paperclip error when a processor backend is not found&quot; do
     assert_raises(Paperclip::ProcessorNotFound){ Paperclip::Processor.for(:nothing) }
   end
 
-  should &quot;define a make method that takes 3 arguments with 1 optional&quot; do
-    assert_equal -3, Paperclip::Processor.new.method(:make).arity
+  should &quot;define a make method on the class that takes 3 arguments with 1 optional&quot; do
+    assert_equal -3, Paperclip::Processor.method(:make).arity
+  end
+
+  should &quot;define a make instance method that does not take any arguments&quot; do
+    assert Paperclip::Processor.instance_methods.include?('make')
+  end
+
+  should &quot;define a :file accessor&quot; do
+    assert Paperclip::Processor.instance_methods.include?('file')
+    assert Paperclip::Processor.instance_methods.include?('file=')
+  end
+
+  should &quot;define an :options accessor&quot; do
+    assert Paperclip::Processor.instance_methods.include?('options')
+    assert Paperclip::Processor.instance_methods.include?('options=')
+  end
+
+  should &quot;define an :attachment accessor&quot; do
+    assert Paperclip::Processor.instance_methods.include?('attachment')
+    assert Paperclip::Processor.instance_methods.include?('attachment=')
   end
 end</diff>
      <filename>test/unit/processor_test.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>158192233d3dd32a9e9d939fc4a2c56f9158bd31</id>
    </parent>
  </parents>
  <author>
    <name>Jon Yurek</name>
    <email>jyurek@thoughtbot.com</email>
  </author>
  <url>http://github.com/thoughtbot/paperclip/commit/322c4f44b6b343e7e6994eb616ce766a5eff023b</url>
  <id>322c4f44b6b343e7e6994eb616ce766a5eff023b</id>
  <committed-date>2009-10-27T21:02:58-07:00</committed-date>
  <authored-date>2009-10-27T21:02:58-07:00</authored-date>
  <message>Changed the interface for the processors for ease of testing</message>
  <tree>82ef50eb143346259993588d01b31e76c455c236</tree>
  <committer>
    <name>Jon Yurek</name>
    <email>jyurek@thoughtbot.com</email>
  </committer>
</commit>
