[importer] Implement a Postgres connection factory for test suite