]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
fixing pre-commit issues
authorZeke Brechtel <5767468+zkl2@users.noreply.github.com>
Sat, 25 Sep 2021 13:49:32 +0000 (07:49 -0600)
committerZeke Brechtel <5767468+zkl2@users.noreply.github.com>
Sat, 25 Sep 2021 13:49:32 +0000 (07:49 -0600)
test/dialect/postgresql/test_dialect.py

index 9650eaed5cc06aecfcef31ab7e0d31e0d56a8334..9ee00198cad096364d0e841ff7f085647d3890a8 100644 (file)
@@ -256,16 +256,14 @@ $$ LANGUAGE plpgsql;"""
         eq_(cparams["host"], "hostA:portA,hostB,hostC")
 
     def test_psycopg2_disconnect(self):
-        
         class Error(Exception):
             pass
 
         dbapi = mock.Mock()
         dbapi.Error = Error
 
-        # dialect = getattr(pscyopg2_dialect, dialect_name).dialect(dbapi=dbapi)
         dialect = psycopg2_dialect.dialect(dbapi=dbapi)
-        
+
         for error in [
             # these error messages from libpq: interfaces/libpq/fe-misc.c
             # and interfaces/libpq/fe-secure.c.
@@ -286,14 +284,11 @@ $$ LANGUAGE plpgsql;"""
             "SSL SYSCALL error: Operation timed out",
             "SSL SYSCALL error: Bad address",
         ]:
-            eq_(dialect.is_disconnect(
-                Error(error),
-                None, None), True)
+            eq_(dialect.is_disconnect(Error(error), None, None), True)
 
         eq_(dialect.is_disconnect("not an error", None, None), False)
 
 
-
 class PGCodeTest(fixtures.TestBase):
     __only_on__ = "postgresql"