From: Gord Thompson Date: Mon, 5 Jul 2021 17:17:13 +0000 (-0600) Subject: Modernize tests - union X-Git-Tag: rel_1_4_21~4^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f11b221a359f401d47e3b10f1713cfffd90d1c0e;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git Modernize tests - union Change-Id: I2ccb714a249350f23e2b5f78f5f9ffb0d4f7efb0 --- diff --git a/lib/sqlalchemy/testing/warnings.py b/lib/sqlalchemy/testing/warnings.py index fea8a6f0a5..f8d6296a0c 100644 --- a/lib/sqlalchemy/testing/warnings.py +++ b/lib/sqlalchemy/testing/warnings.py @@ -68,7 +68,6 @@ def setup_filters(): # # Core SQL constructs # - r"Set functions such as union\(\), union_all\(\), extract\(\),", r"The legacy calling style of select\(\) is deprecated and will be " "removed", r"The FromClause.select\(\) method will no longer accept keyword " diff --git a/test/dialect/mssql/test_compiler.py b/test/dialect/mssql/test_compiler.py index 2e4a087131..f1f849bf95 100644 --- a/test/dialect/mssql/test_compiler.py +++ b/test/dialect/mssql/test_compiler.py @@ -805,7 +805,7 @@ class CompileTest(fixtures.TestBase, AssertsCompiledSQL): t2.c.col2.in_(["t2col2r2", "t2col2r3"]), ), ) - u = union(s1, s2, order_by=["col3", "col4"]) + u = union(s1, s2).order_by("col3", "col4") self.assert_compile( u, "SELECT t1.col3 AS col3, t1.col4 AS col4 " diff --git a/test/sql/test_query.py b/test/sql/test_query.py index b3d728ab36..005693402d 100644 --- a/test/sql/test_query.py +++ b/test/sql/test_query.py @@ -1202,7 +1202,7 @@ class CompoundTest(fixtures.TablesTest): t2.c.col2.in_(["t2col2r2", "t2col2r3"]), ), ) - u = union(s1, s2, order_by=["col3", "col4"]) + u = union(s1, s2).order_by("col3", "col4") wanted = [ ("aaa", "aaa"), @@ -1225,7 +1225,7 @@ class CompoundTest(fixtures.TablesTest): t2.c.col2.in_(["t2col2r2", "t2col2r3"]), ), ) - u = union(s1, s2, order_by=["col3", "col4"]) + u = union(s1, s2).order_by("col3", "col4") wanted = [ ("aaa", "aaa"),