Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

use explicit Factory.create method

  • Loading branch information...
commit 17fa437b61eab9cccfeae428444ce2e73f17beeb 1 parent aef7544
@senny authored
View
2  lib/backyard/adapter/factory_girl.rb
@@ -7,7 +7,7 @@ def class_for_type(model_type)
end
def create(model_type, attributes)
- Factory(model_type, attributes)
+ factory_girl_class.create(model_type, attributes)
end
def factory_girl_class
View
2  spec/backyard/adapter/factory_girl_spec.rb
@@ -4,7 +4,7 @@
describe "#create" do
it "should delegate to factory_girl" do
- subject.should_receive(:Factory).with(:entry, {:name => '123 Entry'})
+ Factory.should_receive(:create).with(:entry, {:name => '123 Entry'})
subject.create :entry, {:name => '123 Entry'}
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.