move knex connection to separate module, update testing