MCPcopy
hub / github.com/psycopg/psycopg / min_size

Function min_size

tests/pool/test_pool_common_async.py:799–806  ·  view source on GitHub ↗

Return the minimum min_size supported by the pool class.

(pool_cls, num=1)

Source from the content-addressed store, hash-verified

797
798
799def min_size(pool_cls, num=1):
800 """Return the minimum min_size supported by the pool class."""
801 if pool_cls is pool.AsyncConnectionPool:
802 return num
803 elif pool_cls is pool.AsyncNullConnectionPool:
804 return 0
805 else:
806 assert False, pool_cls
807
808
809def delay_connection(monkeypatch, sec):

Callers 15

test_connection_classFunction · 0.70
test_kwargsFunction · 0.70
test_contextFunction · 0.70
test_setup_no_timeoutFunction · 0.70
test_configure_badstateFunction · 0.70
test_configure_brokenFunction · 0.70
test_queueFunction · 0.70
test_queue_sizeFunction · 0.70
test_queue_timeoutFunction · 0.70
test_dead_clientFunction · 0.70
test_broken_reconnectFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected