Sha256: 2b73c1c71116d03e1c19d5698c6a8e0e45934bd39d35e6d77ac2a26d4747b48a
Contents?: true
Size: 485 Bytes
Versions: 2
Compression:
Stored size: 485 Bytes
Contents
class ImagesDataset < Dataset::Base def load images = [ :first, :second, :third, :fourth, :fifth ] images.each_with_index do |image, i| create_record :image, image.to_sym, :title => image.to_s, :caption => "caption for #{image.to_s}", :asset_file_name => "#{image.to_s}.png", :asset_content_type => "image/png", :asset_file_size => i+1*1000, :position => i+1 end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
radiant-images-extension-0.3.3 | spec/datasets/images.rb |
radiant-images-extension-0.3.2 | spec/datasets/images.rb |