From fc31319752945d4d39f70c8278ecd42af240bc64 Mon Sep 17 00:00:00 2001 From: Aymeric Augustin Date: Sat, 7 Jun 2014 17:16:49 +0200 Subject: [PATCH] Fixed test again. Refs #12581. --- tests/backends/tests.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/backends/tests.py b/tests/backends/tests.py index 9d3e4a4bf1..a40a6156e0 100644 --- a/tests/backends/tests.py +++ b/tests/backends/tests.py @@ -701,6 +701,11 @@ class BackendTestCase(TestCase): new_connections = ConnectionHandler(settings.DATABASES) new_connection = new_connections[DEFAULT_DB_ALIAS] + # Initialize the connection and clear initialization statements. + with new_connection.cursor(): + pass + new_connection.queries_log.clear() + try: with new_connection.cursor() as cursor: cursor.execute("SELECT 1" + new_connection.features.bare_select_suffix)