MCPcopy
hub / github.com/psycopg/psycopg / make_dumper

Function make_dumper

tests/test_adapt.py:529–539  ·  view source on GitHub ↗

Create a test dumper appending a suffix to the bytes representation.

(suffix)

Source from the content-addressed store, hash-verified

527
528
529def make_dumper(suffix):
530 """Create a test dumper appending a suffix to the bytes representation."""
531
532 class TestDumper(Dumper):
533 oid = builtins["text"].oid
534 format = pq.Format.TEXT
535
536 def dump(self, s):
537 return (s + suffix).encode("ascii")
538
539 return TestDumper
540
541
542def make_bin_dumper(suffix):

Callers 15

test_as_string_contextFunction · 0.85
test_as_bytes_contextFunction · 0.85
test_dump_global_ctxFunction · 0.85
test_dump_connection_ctxFunction · 0.85
test_dump_cursor_ctxFunction · 0.85
test_cow_dumpersFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…