(self)
| 208 | ) |
| 209 | |
| 210 | def test_table_valued_advice(self): |
| 211 | msg = ( |
| 212 | r"SQL expression element expected, got %s. To create a " |
| 213 | r"column expression from a FROM clause row as a whole, " |
| 214 | r"use the .table_valued\(\) method." |
| 215 | ) |
| 216 | assert_raises_message( |
| 217 | exc.ArgumentError, |
| 218 | msg % ("Table.*",), |
| 219 | expect, |
| 220 | roles.ExpressionElementRole, |
| 221 | t, |
| 222 | ) |
| 223 | |
| 224 | # no table_valued() message here right now, it goes to scalar subquery |
| 225 | with testing.expect_warnings( |
| 226 | "implicitly coercing SELECT object to scalar subquery" |
| 227 | ): |
| 228 | expect(roles.ExpressionElementRole, t.select().alias()) |
| 229 | |
| 230 | def test_raise_on_regular_python_obj_for_expr(self): |
| 231 | """test #6350""" |
nothing calls this directly
no test coverage detected