gitlabhq/gitlabhq — pull request #1323 by tsigo (2012-08-29 01:31:34+00:00)
Title: FactoryGirl and spec cleanup

Adds FactoryGirl as we discussed. I didn't go completely crazy with cleaning up specs yet, I wanted to get this merged in first and then I'll start on that.

But this does have one major cleanup: We now only need one seed repository, and it should also eliminate all instances of tests randomly failing because a Project got a duplicate value from Faker. I moved the seed repos from `tmp/tests` to `tmp/repositories`, so you'll need to re-run `db:seed_fu RAILS_ENV=test`.

@randx Please take a look at `StubbedRepository` -- I wrote this last night before your changes, so there may be some overlap in our methods.