<commit_before>require 'factory_girl'

Factory.sequence :login do |n|
  "gandhi_#{n}"
end

Factory.sequence :email do |n|
  "<EMAIL>"
end

Factory.sequence :name do |n|
  "Teambox ##{n}"
end

Factory.sequence :permalink do |n|
  "teambox#{n}"
end

Factory.define :user do |user|
  user.login { Factory.next(:login) }
  user.email { Factory.next(:email) }
  user.first_name 'Andrew'
  user.last_name 'Wiggin'
  user.password '<PASSWORD>'
  user.password_confirmation '<PASSWORD>'
end

Factory.define :confirmed_user, :class => User do |user|
  user.login { Factory.next(:login) }
  user.email { Factory.next(:email) }
  user.first_name 'Andrew'
  user.last_name 'Wiggin'
  user.password '<PASSWORD>'
  user.password_confirmation '<PASSWORD>'
  user.confirmed_user true
end

Factory.define :person do |person|
  person.association(:project)
  person.association(:user)
end

Factory.define :project do |project|
  project.name { Factory.next(:name) }
  project.association(:user)
end

Factory.define :group do |group|
  group.name { Factory.next(:name) }
  group.permalink { Factory.next(:permalink) }
  group.association(:user)
end

Factory.define :conversation do |conversation|<commit_msg>make project factory use "confirmed_user" as owner<commit_after>require 'factory_girl'

Factory.sequence :login do |n|
  "gandhi_#{n}"
end

Factory.sequence :email do |n|
  "<EMAIL>"
end

Factory.sequence :name do |n|
  "Teambox ##{n}"
end

Factory.sequence :permalink do |n|
  "teambox#{n}"
end

Factory.define :user do |user|
  user.login { Factory.next(:login) }
  user.email { Factory.next(:email) }
  user.first_name 'Andrew'
  user.last_name 'Wiggin'
  user.password '<PASSWORD>'
  user.password_confirmation '<PASSWORD>'
end

Factory.define :confirmed_user, :parent => :user do |user|
  user.confirmed_user true
end

Factory.define :person do |person|
  person.association(:project)
  person.association(:user)
end

Factory.define :project do |project|
  project.name { Factory.next(:name) }
  project.association(:user, :factory => :confirmed_user)
end

Factory.define :group do |group|
  group.name { Factory.next(:name) }
  group.permalink { Factory.next(:permalink) }
  group.association(:user)
end

Factory.define :conversation do |conversation|
{'fraction_non_alphanumeric': 0.13891362422083706, 'fraction_numerical': 0.0, 'mean_word_length': 4.913157894736842, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 14, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5748591', 'n_tokens_mistral': 786, 'n_tokens_neox': 781, 'n_words': 183}