MCPcopy Create free account
hub / github.com/alpha2phi/python-apps / test_db_provider

Method test_db_provider

excel-ingester/tests/test_ingester.py:16–29  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

14 """Ingester cases."""
15
16 def test_db_provider(self):
17 db_provider = DbProvider()
18 db_provider.register_builder("pgsql", PgSqlDbBuilder())
19
20 config = {
21 "host": "pgsql",
22 "port": 1200,
23 "user": "test_user",
24 "password": "test_password",
25 }
26
27 db = db_provider.get("pgsql", **config)
28 assert db is not None
29 logging.info(db.get_conn_str())
30
31 def test_ingest_pgsql(self):
32 ingest("data/accounts.xlsx", "testdb", "accounts", "pgsql")

Callers

nothing calls this directly

Calls 6

getMethod · 0.95
DbProviderClass · 0.85
PgSqlDbBuilderClass · 0.85
register_builderMethod · 0.80
get_conn_strMethod · 0.80
infoMethod · 0.45

Tested by

no test coverage detected