Skip to content

Commit

Permalink
use new factory_girl syntax and remove deprecated confirmed_email_user
Browse files Browse the repository at this point in the history
  • Loading branch information
drapergeek committed Mar 30, 2012
1 parent f78bcae commit 852297b
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions spec/factories.rb
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
Factory.sequence :email do |n|
"user#{n}@example.com"
end
FactoryGirl.define do

Factory.define :user do |factory|
factory.email { Factory.next :email }
factory.password { "password" }
end
sequence :email do |n|
"user#{n}@example.com"
end

factory :user do
email
password "password"
end

Factory.define :email_confirmed_user, :parent => :user do |factory|
factory.after_build { warn "[DEPRECATION] The :email_confirmed_user factory is deprecated, please use the :user factory instead." }
end

0 comments on commit 852297b

Please sign in to comment.