]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
fix incorrect use of testing.future()
authorMike Bayer <mike_mp@zzzcomputing.com>
Thu, 26 Jan 2023 01:19:10 +0000 (20:19 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Thu, 26 Jan 2023 03:19:25 +0000 (22:19 -0500)
this has been emitting a warning probably for a long
time

Change-Id: I44a6766b5e92d14ce6bbb5a90ab52648f877afc2

lib/sqlalchemy/testing/exclusions.py
test/orm/test_cascade.py
test/orm/test_query.py

index 7ec43128b88855af32795c718bd338b8e6ba1bd7..09cf5b3247a9e5de2820ec02bf0b18a819fab664 100644 (file)
@@ -400,9 +400,8 @@ def fails(reason=None):
     return fails_if(BooleanPredicate(True, reason or "expected to fail"))
 
 
-@decorator
-def future(fn, *arg):
-    return fails_if(LambdaPredicate(fn), "Future feature")
+def future():
+    return fails_if(BooleanPredicate(True, "Future feature"))
 
 
 def fails_on(db, reason=None):
index 0e9e63c260170fa084eb6cc1d2b5d30da0cf1a3b..a461647037d9d253669ada44be6e7f545942f944 100644 (file)
@@ -2283,7 +2283,7 @@ class M2OCascadeDeleteNoOrphanTest(fixtures.MappedTest):
         eq_(sess.query(T2).all(), [T2()])
         eq_(sess.query(T3).all(), [T3()])
 
-    @testing.future
+    @testing.future()
     def test_preserves_orphans_onelevel_postremove(self):
         T2, T3, T1 = (self.classes.T2, self.classes.T3, self.classes.T1)
 
index 9e303a778b0e64498f8793db1479fe9735637703..9ca74cb841a3b4543482e635a76c9a542f5d6a64 100644 (file)
@@ -7402,7 +7402,7 @@ class ImmediateTest(_fixtures.FixtureTest):
             .one_or_none,
         )
 
-    @testing.future
+    @testing.future()
     def test_getslice(self):
         assert False