Add option to database_connection so that logging can be turned on via object creation.

Signed-off-by: Scott Zawalski <scottz@google.com>


git-svn-id: http://test.kernel.org/svn/autotest/trunk@4283 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/database/database_connection.py b/database/database_connection.py
index e1e3222..ca5f491 100644
--- a/database/database_connection.py
+++ b/database/database_connection.py
@@ -147,11 +147,11 @@
     _DATABASE_ATTRIBUTES = ('db_type', 'host', 'username', 'password',
                             'db_name')
 
-    def __init__(self, global_config_section=None):
+    def __init__(self, global_config_section=None, debug=False):
         self.global_config_section = global_config_section
         self._backend = None
         self.rowcount = None
-        self.debug = False
+        self.debug = debug
 
         # reconnect defaults
         self.reconnect_enabled = True