MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / test_bindparam_coercion

Method test_bindparam_coercion

test/sql/test_operators.py:4879–4888  ·  view source on GitHub ↗

test #7979

(self, t_fixture, legacy_any_all_operators)

Source from the content-addressed store, hash-verified

4877 )
4878
4879 def test_bindparam_coercion(self, t_fixture, legacy_any_all_operators):
4880 """test #7979"""
4881 t = t_fixture
4882 op, fn = legacy_any_all_operators
4883
4884 expr = fn(t.c.arrval, bindparam("param"))
4885 expected = f"%(param)s = {op} (tab1.arrval)"
4886 is_(expr.left.type._type_affinity, Integer)
4887
4888 self.assert_compile(expr, expected, dialect="postgresql")
4889
4890 def test_array_comparator_accessor(
4891 self, t_fixture, legacy_any_all_operators

Callers

nothing calls this directly

Calls 3

bindparamFunction · 0.90
is_Function · 0.90
assert_compileMethod · 0.80

Tested by

no test coverage detected