def process_bind_param(self, value, dialect): if value is None: return None assert value.startswith(self._implicit) return b''.join([ serialize_varint(len(value)-len(self._implicit)), value[len(self._implicit):].tobytes()])
def process_bind_param(self, value, dialect): if value is None: return None assert value.startswith(self._implicit) return b''.join([ serialize_varint(len(value) - len(self._implicit)), value[len(self._implicit):].tobytes() ])
def __test__(self, long_, result): self.assertEqual(serialize_varint(long_), result)