summaryrefslogtreecommitdiff
path: root/django/test
diff options
context:
space:
mode:
Diffstat (limited to 'django/test')
-rw-r--r--django/test/signals.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/test/signals.py b/django/test/signals.py
index f7836637e8..bb04af6efb 100644
--- a/django/test/signals.py
+++ b/django/test/signals.py
@@ -69,7 +69,7 @@ def update_connections_time_zone(**kwargs):
except AttributeError:
pass
tz_sql = conn.ops.set_time_zone_sql()
- if tz_sql:
+ if tz_sql and conn.timezone_name:
with conn.cursor() as cursor:
cursor.execute(tz_sql, [conn.timezone_name])