Closed dadair-ca closed 9 years ago
Thanks, I'll accept the pull request as soon as I can. The output you're referring to is logging information triggered by one of the tests - it's intentional. If migrations are part of your system startup, you can end up in a situation where fixtures are being run before you've had the chance to actually migrate the database. Therefore, I provided an outlet for a small bit of logging output to alert the user to that fact.
There's got to be a more robust way to deal with that. Any thoughts?
Hmm I can give it some thought. I think for now, maybe just simplify the output?
Ex: "Couldn't find table 'non_existing_table'". Do you have migrations to run?"
Although this error might be confusing, as people may think the library itself deals with migrations.
Maybe keep it the way it is, but have a part of the README dedicated to this? It could explain that you may need to update your database, with an example of using ragtime?
And since this PR would be considered a breaking change, maybe bump the major version? I bumped the minor but minors shouldn't break builds.
Duct components such as Ragtime require the datastore to be identified by
:db
, while this component requires:store
. To reduce friction for integrating with Duct, I've updated this component from:store
=>:db
. This is also in-line with more common clojure name conventions for databases.I've tested the changes in a local Duct project, and was able to run both migrations (using Ragtime) and fixtures (using this component), so the renaming is working.
I tried running tests, but I got the following output:
I checked out the base repository into a new directory, and ran the migrations and the tests, and received the same output, so I am not sure what is going on with the repository's tests, but both my changes and the base repository output the same (above).