Try out Oaken for seeds and test data
Paired with @marcoroth
- [ ] Fix db:seed test.
thanks @kaspth and @marcoroth for this PR. Oaken was something I wanted to try out but never really got the time for it. I like how this looks.
While chatting quickly with @marcoroth I understand that the production seed is the issue that remains to be solved. up to now I was using the seed task to update new content in production. I know it is not really a task that we are due to run in production but so far in our particular case it worked quite well. This being said I wouldn't be opposed to having a dedicated task for ingesting data in prod (and dev for setup) if this could make it easier
PS sorry lots of conflit to solve. They where a large backlog of PR waiting to be merge....
I've been wondering if we even should use fixtures/test data in the first place. Would it make sense to just use the actual data in data/ for the tests and write the tests with that in mind?
heyo, sorry for being out of the loop on this one!
I've been wondering if we even should use fixtures/test data in the first place. Would it make sense to just use the actual data in data/ for the tests and write the tests with that in mind?
@marcoroth this makes sense to me if that's easier.
up to now I was using the seed task to update new content in production. I know it is not really a task that we are due to run in production but so far in our particular case it worked quite well.
@adrienpoly all good, I think having production specific seeds is going to be more common in the future — Oaken is trying to suggest this to people too. I'd just recommend running Rails.application.load_seed directly, which is what the rake db:seed task calls.