Add group_scores to groups factory, one for every team

This commit is contained in:
Daniel Schädler 2019-05-29 22:41:09 +02:00
parent cde4934c48
commit d50cd66b24
1 changed files with 3 additions and 0 deletions

View File

@ -11,6 +11,9 @@ FactoryBot.define do
after(:create) do |group, evaluator|
create_list(:group_match, evaluator.match_count, group: group)
group.group_scores = group.teams.map do |team|
create(:group_score, team: team, group: group)
end
end
end
end