Fabricator of a model that has a column named `klass' #92
Comments
ah, Fabricator(:foo) do
after_build {|foo| foo.klass = 'value' }
end works around the issue. |
In the context of the Fabricator block, Ruby thinks you're referring to the I can't think of a better solution than yours, or to treat |
This is definitely a bug in fabrication. In the mean time, you can either use Matt's workaround with the after_build callback or name your attribute something else. -- Paul On Wednesday, March 7, 2012 at 12:09 PM, Matthew Conway wrote:
|
It seems there are a lot of methods that can collide when in the context of a Fabricator: (rdb:1) self.methods.sort |
the snippet below spills an ArgumentError (wrong number of arguments (1 for 0)).
is there any means to avoid that?
The text was updated successfully, but these errors were encountered: