Fix DB deprecation warnings when using HSQLDB

In the case of a non-existent database (for instance, during the first
run), we were opening a connection to retrieve the database info for the
deprecation warning, and then closing the connection without creating
anything. This seems to confuse the DB for reasons that aren't exactly
clear. When we then open another connection to migrate, it hangs.

Now the warn-on-db-deprecation! function expects to be called within an
open connection, rather than taking the db as a parameter and opening
the connection itself. This is more consistent with other functions like
it, and also lets us use the same connection for warn-on-db-deprecation!
and migrate!, which means there will always be something in the database
hwne we close our first connection.
Merge pull request #397 from nicklewis/deprecations-with-hsqldb

Fix DB deprecation warnings when using HSQLDB