Posts tagged with machinist (2)

Jan12 Machinist and polymorphic associations post author

machinist polymorphic | comments

You love machinist for fixtures creation, but then you need to blueprint a model that has a polymorphic association and that means two fields in your blueprint. Don’t worry, it’s dead easy using a helper class.

Continue reading »

Dec21 Rake + Machinist: centralizing data creation post author

rake machinist | comments

Machinist is my favourite choice for sample data creation in my specs, but you know sometimes you need seed data, e. g. to play with your site in the browser. It is pretty simple to call your blueprints from a rake task that depends on the environment task: the trick is to require your blueprint inside the task body.

Continue reading »