[Django] #35986: Some unit tests in forms_tests.tests.test_input_formats not running

9 views
Skip to first unread message

Django

unread,
Dec 9, 2024, 5:22:51 AM12/9/24
to django-...@googlegroups.com
#35986: Some unit tests in forms_tests.tests.test_input_formats not running
-------------------------------------+-------------------------------------
Reporter: Arthur Pemberton | Type: Bug
Status: new | Component:
| Uncategorized
Version: 5.1 | 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
-------------------------------------+-------------------------------------
For example, the test "CustomTimeInputFormatsTests" does not get
discovered and ran via:
`./runtests.py forms_tests.tests.test_input_formats`

And attempting to run the test direct with `./runtests.py
forms_tests.tests.test_input_formats.CustomTimeInputFormatsTests` results
in an error:
AttributeError: 'CustomTimeInputFormatsTests' object has no attribute
'runTest'. Did you mean: 'subTest'?

Using Python 3.12, I followed the steps from
https://docs.djangoproject.com/en/dev/internals/contributing/writing-code
/unit-tests/#running-the-unit-tests to setup a clean environment.
--
Ticket URL: <https://code.djangoproject.com/ticket/35986>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Dec 9, 2024, 5:23:02 AM12/9/24
to django-...@googlegroups.com
#35986: Some unit tests in forms_tests.tests.test_input_formats not running
----------------------------------+--------------------------------------
Reporter: Arthur Pemberton | Owner: (none)
Type: Bug | Status: new
Component: Uncategorized | Version: 5.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+--------------------------------------
Changes (by Arthur Pemberton):

* Attachment "test_input_formats-output.txt" added.

Django

unread,
Dec 9, 2024, 5:27:56 AM12/9/24
to django-...@googlegroups.com
#35986: Some unit tests in forms_tests.tests.test_input_formats not running
----------------------------------+--------------------------------------
Reporter: Arthur Pemberton | Owner: (none)
Type: Bug | Status: new
Component: Uncategorized | Version: 5.1
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+--------------------------------------
Comment (by Arthur Pemberton):

From that module, the following tests are seemingly all affected:
* CustomTimeInputFormatsTests
* CustomDateInputFormatsTests
* CustomDateTimeInputFormatsTests
--
Ticket URL: <https://code.djangoproject.com/ticket/35986#comment:1>
Reply all
Reply to author
Forward
0 new messages