spec/factories/factories.rb in symphonia-3.2.4 vs spec/factories/factories.rb in symphonia-3.3.0
- old
+ new
@@ -4,11 +4,10 @@
sequence(:last_name) { |n| "#{Faker::Name.last_name} #{n}" }
sequence(:email) { |n| "#{n}" + Faker::Internet.email }
login { email }
admin { false }
password { SecureRandom.hex(16) }
- # password_confirmation { password }
last_request_at { Time.now }
trait :admin do
admin { true }
end
@@ -26,20 +25,20 @@
factory :role, class: 'Symphonia::Role' do
sequence(:name) { |n| "#{Faker::Job.title} #{n}" }
end
- factory :attachment, class: 'Symphonia::Attachment' do
- association :attachable, factory: :user
- end
-
- factory :file, parent: :attachment, class: 'Symphonia::CommonFile' do
- attachment { File.new(File.expand_path('../../support/common_file.txt', __FILE__)) }
- end
-
- factory :image, parent: :attachment, class: 'Symphonia::Image' do
- attachment { File.new(File.expand_path('../../support/symphonia.jpg', __FILE__)) }
- end
+ # factory :attachment, class: 'Symphonia::Attachment' do
+ # association :attachable, factory: :user
+ # end
+ #
+ # factory :file, parent: :attachment, class: 'Symphonia::CommonFile' do
+ # attachment { File.new(File.expand_path('../../support/common_file.txt', __FILE__)) }
+ # end
+ #
+ # factory :image, parent: :attachment, class: 'Symphonia::Image' do
+ # attachment { File.new(File.expand_path('../../support/symphonia.jpg', __FILE__)) }
+ # end
factory :preference, class: 'Symphonia::Preference' do
factory :email_preference, class: 'Symphonia::EmailPreference' do
trait :user_registered do