Sha256: 487039da77cf423995759a2448c53ad853bfb82b769611c0dfc35c208b3b3610

Contents?: true

Size: 269 Bytes

Versions: 19

Compression:

Stored size: 269 Bytes

Contents

[Tweet, Favorite, User].map(&:delete_all)

(1..5).each do |count|
  user  = User.create
  tweet = Tweet.create(user: user)

  count.times do
    user = User.create
    Favorite.create(tweet: tweet, user: user)
    Tweet.create(in_reply_to: tweet, user: user)
  end
end

Version data entries

19 entries across 19 versions & 2 rubygems

Version Path
activerecord-precount-0.7.0 sample/db/seeds.rb
activerecord-precount-0.7.0.beta1 sample/db/seeds.rb
activerecord-precount-0.6.3 sample/db/seeds.rb
activerecord-precount-0.6.2 sample/db/seeds.rb
activerecord-precount-0.6.1 sample/db/seeds.rb
activerecord-precount-0.6.0 sample/db/seeds.rb
activerecord-precount-0.5.1 sample/db/seeds.rb
activerecord-precount-0.5.0 sample/db/seeds.rb
activerecord-precount-0.4.3 sample/db/seeds.rb
activerecord-precount-0.4.2 sample/db/seeds.rb
activerecord-precount-0.4.1 sample/db/seeds.rb
activerecord-precount-0.4.0 sample/db/seeds.rb
activerecord-count_loader-0.3.3 sample/db/seeds.rb
activerecord-count_loader-0.3.2 sample/db/seeds.rb
activerecord-count_loader-0.3.1 sample/db/seeds.rb
activerecord-count_loader-0.3.0 sample/db/seeds.rb
activerecord-count_loader-0.2.2 sample/db/seeds.rb
activerecord-count_loader-0.2.1 sample/db/seeds.rb
activerecord-count_loader-0.2.0 sample/db/seeds.rb