MCPcopy Create free account
hub / github.com/MagicStack/asyncpg / test_exceptions_exported

Method test_exceptions_exported

tests/test_exceptions.py:14–23  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

12class TestExceptions(tb.ConnectedTestCase):
13
14 def test_exceptions_exported(self):
15 for err in ('PostgresError', 'SubstringError', 'InterfaceError'):
16 self.assertTrue(hasattr(asyncpg, err))
17 self.assertIn(err, asyncpg.__all__)
18
19 for err in ('PostgresMessage',):
20 self.assertFalse(hasattr(asyncpg, err))
21 self.assertNotIn(err, asyncpg.__all__)
22
23 self.assertIsNone(asyncpg.PostgresError.schema_name)
24
25 async def test_exceptions_unpacking(self):
26 try:

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected