diff --git a/tests/regressiontests/queries/models.py b/tests/regressiontests/queries/models.py index debce6ad50..e2d56e185f 100644 --- a/tests/regressiontests/queries/models.py +++ b/tests/regressiontests/queries/models.py @@ -903,12 +903,12 @@ Pickling of DateQuerySets used to fail """} -# In Python 2.3, exceptions raised in __len__ are swallowed (Python issue -# 1242657), so these cases return an empty list, rather than raising an -# exception. Not a lot we can do about that, unfortunately, due to the way -# Python handles list() calls internally. Thus, we skip the tests for Python -# 2.3. -if sys.version_info >= (2, 4): +# In Python 2.3 and the Python 2.6 beta releases, exceptions raised in __len__ +# are swallowed (Python issue 1242657), so these cases return an empty list, +# rather than raising an exception. Not a lot we can do about that, +# unfortunately, due to the way Python handles list() calls internally. Thus, +# we skip the tests for Python 2.3 and 2.6. +if (2, 4) <= sys.version_info < (2, 6): __test__["API_TESTS"] += """ # If you're not careful, it's possible to introduce infinite loops via default # ordering on foreign keys in a cycle. We detect that.