FactoryGirl does not currently support initializers with arguments. Therefore, when you start build it tries to execute Room.new .
One of the easiest ways to solve this problem is to deactivate your classes in a test setup to work around this problem. This is not an ideal solution, but you can run tests.
Thus, you will need to do one of them (only in your test installation code):
class Room def initialize(length = nil, width = nil) ... end end
or
class Room def initialize ... end end
The issue is discussed here:
https://github.com/thoughtbot/factory_girl/issues/42
... and here:
https://github.com/thoughtbot/factory_girl/issues/19
Casper
source share