mirror of
https://github.com/evennia/evennia.git
synced 2026-03-30 04:27:16 +02:00
Move to python3 style exec.
This commit is contained in:
parent
418ca41803
commit
b7577f13cd
1 changed files with 2 additions and 2 deletions
|
|
@ -15,10 +15,10 @@ def count_queries(exec_string, setup_string):
|
|||
to setup the environment to test.
|
||||
"""
|
||||
|
||||
exec setup_string
|
||||
exec(setup_string)
|
||||
|
||||
num_queries_old = len(connection.queries)
|
||||
exec exec_string
|
||||
exec(exec_string)
|
||||
nqueries = len(connection.queries) - num_queries_old
|
||||
|
||||
for query in connection.queries[-nqueries if nqueries else 1:]:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue