object.rb 188 B

12345
  1. FactoryBot.define do
  2. factory :'tag/object', aliases: %i[tag_object] do
  3. name { (ApplicationModel.descendants.select(&:any?).map(&:name) - Tag::Object.pluck(:name)).sample }
  4. end
  5. end