Posted 12 days ago. Visible to the public. Linked content. Auto-destruct in 48 days

Updated: Don't use migrations to seed default data

It's OK to add data in a migration if your test suite cleans the database before it starts.

For instance, in RSpec:

config.before(:suite) do DatabaseCleaner.clean_with(:deletion) end
Growing Rails Applications in Practice
Check out our new e-book:
Learn to structure large Ruby on Rails codebases with the tools you already know and love.

Owner of this card:

Henning Koch
Last edit:
12 days ago
by Henning Koch
About this deck:
We are makandra and do test-driven, agile Ruby on Rails software development.
License for source code
Posted by Henning Koch to makandra dev
This website uses short-lived cookies to improve usability.
Accept or learn more