Sha256: 7193c1199bc0aa16db7f9d23f01e348eb2364e3c0c1f40c2512b9622e4ad65bd

Contents?: true

Size: 378 Bytes

Versions: 18

Compression:

Stored size: 378 Bytes

Contents

Factory.sequence :name do |n|
  "a_name#{n}"
end

Factory.define :user do |f|
  f.name { Factory.next(:name) }
end

Factory.define :upload do |f|
  f.creator {|a| a.association(:user)}
  f.uploadable {|a| a.association(:user)}
  f.caption { Factory.next(:name) }
  f.local ActionController::TestUploadedFile.new(File.join(RAILS_ROOT, 'public/images/rails.png'), 'image/gif')
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
uploader-0.2.8 test/rails_root/test/factories.rb
uploader-0.2.7 test/rails_root/test/factories.rb
uploader-0.2.6 test/rails_root/test/factories.rb
uploader-0.2.5 test/rails_root/test/factories.rb
uploader-0.2.4 test/rails_root/test/factories.rb
uploader-0.2.3 test/rails_root/test/factories.rb
uploader-0.2.2 test/rails_root/test/factories.rb
uploader-0.2.1 test/rails_root/test/factories.rb
uploader-0.2.0 test/rails_root/test/factories.rb
uploader-0.1.19 test/rails_root/test/factories.rb
uploader-0.1.20 test/rails_root/test/factories.rb
uploader-0.1.16 test/rails_root/test/factories.rb
uploader-0.1.17 test/rails_root/test/factories.rb
uploader-0.1.18 test/rails_root/test/factories.rb
uploader-0.1.14 test/rails_root/test/factories.rb
uploader-0.1.13 test/rails_root/test/factories.rb
uploader-0.1.15 test/rails_root/test/factories.rb
uploader-0.1.12 test/rails_root/test/factories.rb