orbit-personalconference/spec/factories/conference_co_author_relati...

12 lines
377 B
Ruby
Raw Normal View History

2014-01-15 10:49:46 +00:00
types = ["friend", "teacher", "student", "schoolmate", "parent", "best friend", "instructor", "labmate", "TA", "mate"]
FactoryGirl.define do
factory(:conference_co_author_relation, class: "ConferenceCoAuthorRelation") do |f|
f.sequence(:relation_translations) do |n|
{ zh_tw: "#{types[n%types.size]}",
en: "#{types[n%types.size]}" }
end
end
end