

def test_render_subquery(self):
    (users, addresses) = (self.tables.users, self.tables.addresses)
    checkparams = {
        'email_address_1': 'e1',
        'id_1': 7,
        'name': 'newname',
    }
    cols = [addresses.c.id, addresses.c.user_id, addresses.c.email_address]
    subq = select(cols).where((addresses.c.id == 7)).alias()
    self.assert_compile(users.update().values(name='newname').where((users.c.id == subq.c.user_id)).where((subq.c.email_address == 'e1')), 'UPDATE users SET name=:name FROM (SELECT addresses.id AS id, addresses.user_id AS user_id, addresses.email_address AS email_address FROM addresses WHERE addresses.id = :id_1) AS anon_1 WHERE users.id = anon_1.user_id AND anon_1.email_address = :email_address_1', checkparams=users)

dataset/ETHPy150Open zzzeek/sqlalchemy/test/sql/test_update.py UpdateFromCompileTest.test_render_subquery/VarMisuse@148/295 `checkparams`->`users`