MCPcopy Index your code
hub / github.com/zzzeek/sqlalchemy / _assert_token_in_execute

Method _assert_token_in_execute

test/engine/test_logging.py:966–974  ·  view source on GitHub ↗
(self, conn, token)

Source from the content-addressed store, hash-verified

964 log.removeHandler(self.buf)
965
966 def _assert_token_in_execute(self, conn, token):
967 self.buf.flush()
968 r = conn.execute(select(1))
969 r.all()
970 assert self.buf.buffer
971 for rec in self.buf.buffer:
972 line = rec.msg % rec.args
973 assert re.match(r"\[%s\]" % token, line)
974 self.buf.flush()
975
976 def _assert_no_tokens_in_execute(self, conn):
977 self.buf.flush()

Calls 5

selectFunction · 0.90
flushMethod · 0.45
executeMethod · 0.45
allMethod · 0.45
matchMethod · 0.45

Tested by

no test coverage detected