Sha256: cc7585c503575080d633911d18591777dde1189d2421c5230b0cc43f589599db
Contents?: true
Size: 854 Bytes
Versions: 21
Compression:
Stored size: 854 Bytes
Contents
# Copyright 2021 Google LLC # # Use of this source code is governed by an MIT-style # license that can be found in the LICENSE file or at # https://opensource.org/licenses/MIT. require_relative "../../config/environment.rb" require_relative "../models/singer" require_relative "../models/album" first_names = ["Pete", "Alice", "John", "Ethel", "Trudy", "Naomi", "Wendy"] last_names = ["Wendelson", "Allison", "Peterson", "Johnson", "Henderson", "Ericsson", "Aronson"] adjectives = ["daily", "happy", "blue", "generous", "cooked", "bad", "open"] nouns = ["windows", "potatoes", "bank", "street", "tree", "glass", "bottle"] 10.times do Singer.create first_name: first_names.sample, last_name: last_names.sample end 30.times do singer_id = Singer.all.sample.id Album.create title: "#{adjectives.sample} #{nouns.sample}", singer_id: singer_id end
Version data entries
21 entries across 21 versions & 1 rubygems