Skip to content

Commit f4edb22

Browse files
committed
pyupgrade
1 parent 31184cc commit f4edb22

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

test/integ/test_connection.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -331,29 +331,29 @@ def exe(sql):
331331
current_db = cnx.database
332332
current_schema = cnx.schema
333333

334-
exe("use {}".format(current_db))
334+
exe(f"use {current_db}")
335335
exe("create or replace role snowdog_role")
336336
exe("grant role snowdog_role to user snowdog")
337337
try:
338338
# This statement will be partially executed because REFERENCE_USAGE
339339
# will not be granted.
340-
exe("grant all on database {} to role snowdog_role".format(current_db))
340+
exe(f"grant all on database {current_db} to role snowdog_role")
341341
except ProgrammingError as error:
342342
err_str = (
343343
"Grant partially executed: privileges [REFERENCE_USAGE] not granted."
344344
)
345345
assert 3011 == error.errno
346346
assert error.msg.find(err_str) != -1
347-
exe("grant all on schema {} to role snowdog_role".format(current_schema))
347+
exe(f"grant all on schema {current_schema} to role snowdog_role")
348348

349349
with conn_cnx(user="snowdog", password="testdoc") as cnx2:
350350

351351
def exe(sql):
352352
return cnx2.cursor().execute(sql)
353353

354354
exe("use role snowdog_role")
355-
exe("use {}".format(current_db))
356-
exe("use schema {}".format(current_schema))
355+
exe(f"use {current_db}")
356+
exe(f"use schema {current_schema}")
357357
exe("create or replace table friends(name varchar(100))")
358358
exe("drop table friends")
359359
with conn_cnx() as cnx:
@@ -362,7 +362,7 @@ def exe(sql):
362362
return cnx.cursor().execute(sql)
363363

364364
exe("use role accountadmin")
365-
exe("revoke all on database {} from role snowdog_role".format(current_db))
365+
exe(f"revoke all on database {current_db} from role snowdog_role")
366366
exe("drop role snowdog_role")
367367
exe("drop user if exists snowdog")
368368

0 commit comments

Comments
 (0)