[Django] #33633: test_reset_sequences fails for backends not supporting transactions

6 views
Skip to first unread message

Django

unread,
Apr 10, 2022, 8:35:17 AM4/10/22
to django-...@googlegroups.com
#33633: test_reset_sequences fails for backends not supporting transactions
---------------------------------------------+------------------------
Reporter: Xiang Zhang | Owner: nobody
Type: Uncategorized | Status: new
Component: Testing framework | Version: 4.0
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
---------------------------------------------+------------------------
{{{
FAIL: test_reset_sequences (test_utils.test_testcase.TestTestCase)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/zhangyangyu/repos/django-
tidb/django_tests_dir/django/tests/test_utils/test_testcase.py", line 47,
in test_reset_sequences
old_reset_sequences = self.reset_sequences
File
"/opt/homebrew/Cellar/python@3.9/3.9.12/Frameworks/Python.framework/Versions/3.9/lib/python3.9/contextlib.py",
line 126, in __exit__
next(self.gen)
File "/Users/zhangyangyu/repos/django-
tidb/django_tests_dir/django/django/test/testcases.py", line 807, in
_assert_raises_or_warns_cm
yield cm
AssertionError: TypeError not raised
}}}

`test_reset_sequences` fails with above error if testing against backends
not supporting transactions, like MySQL MyIASM engine.

--
Ticket URL: <https://code.djangoproject.com/ticket/33633>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Reply all
Reply to author
Forward
0 new messages