Move test config to a separate file

* make it possible to have a separate DB for tests
* easier to isolate settings for tests

Also adds a t/bin/initialize-db script to run the commands required to
initialize the DB so that tests can run