Opened 11 years ago
Closed 11 years ago
#21720 closed Bug (fixed)
python manage.py test fails with empty test label
Reported by: | Preston Timmons | Owned by: | Preston Timmons |
---|---|---|---|
Component: | Testing framework | Version: | dev |
Severity: | Release blocker | Keywords: | |
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | yes | UI/UX: | no |
Description
The bug fix in #21206 introduced a new bug.
When python manage.py test is run without test labels the is_discoverable function raises a TypeError.
TypeError: relative imports require the 'package' argument
Test labels are set to "." when not specified.
This can be reproduced by running the tests with a new project from django-admin.py
Change History (4)
comment:1 by , 11 years ago
Severity: | Normal → Release blocker |
---|---|
Triage Stage: | Unreviewed → Accepted |
comment:2 by , 11 years ago
Easy pickings: | set |
---|
comment:4 by , 11 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
(Sorry, wrong ticket number in real commit message)
In 18d962f2e6cc8829d60d6f6dfb3ee3855fa5362e:
Fixed #21206 -- Fixed test discovery without labels Added test to verify an empty label performs discovery on the current working directory.
Note:
See TracTickets
for help on using tickets.
The fix should be rather easy, probably special-casing
label == '.'
inis_discoverable
.