For automated testing, RSpec and FactoryGirl are used.
Frequently, I need to manually play with my application. So, i need a convenient way to populate database with some data.
The most convenient way to do it - is fixtures, because they handling relationships between models very well.
I know, that i can load fixtures via rake db:fixtures:load command, but sometimes i need to populate only specific models (say, only customers --> orders --> products)
I'm looking for a command, like this:
rake db:fixtures:load --models=customers,orders,products
You can use:
rake db:fixtures:load FIXTURES=customers,orders,products
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With