MCPcopy Index your code
hub / github.com/sqlalchemy/sqlalchemy / test_rmatmul

Method test_rmatmul

test/sql/test_operators.py:1133–1141  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1131 self.assert_compile(Column("x", MyType()) @ 5, "x -> :x_1")
1132
1133 def test_rmatmul(self):
1134 class MyType(UserDefinedType):
1135 cache_ok = True
1136
1137 class comparator_factory(UserDefinedType.Comparator):
1138 def __rmatmul__(self, other):
1139 return self.op("->")(other)
1140
1141 self.assert_compile(5 @ Column("x", MyType()), "x -> :x_1")
1142
1143
1144class JSONIndexOpTest(fixtures.TestBase, testing.AssertsCompiledSQL):

Callers

nothing calls this directly

Calls 3

ColumnClass · 0.90
assert_compileMethod · 0.80
MyTypeClass · 0.70

Tested by

no test coverage detected