1 # This file should contain all the record creation needed to seed the database with its default values.
2 # The data can then be loaded with the rake db:seed (or created alongside the db with db:setup).
6 # cities = City.create([{ name: 'Chicago' }, { name: 'Copenhagen' }])
7 # Mayor.create(name: 'Emanuel', city: cities.first)
10 (1..20).each
do |item_number
|
11 ('a'..'j').each
do |feed_name
|
12 FeedItem
.create(:feed_name => "feed-#{feed_name}",
13 :title => "feed-#{feed_name}-item-" + sprintf("%02d", item_number
),
14 :description => "Feed #{feed_name}, Item #{item_number} has a description")