#6024 closed (fixed)
Django's doctest clashes with coverage.py
| Reported by: | marcink | Owned by: | nobody |
|---|---|---|---|
| Component: | Testing framework | Version: | dev |
| Severity: | Keywords: | ||
| Cc: | Triage Stage: | Ready for checkin | |
| Has patch: | yes | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
When you use coverage.py in "manage.py test" it incorrectly reports
some statements as not executed. This is a known issue with
coverage.py. From http://nedbatchelder.com/code/modules/coverage.html
:
"Older versions of doctest interfere with coverage's tracing of
statements, and you may get reports that none of your code is
executing. Use this patch to doctest.py if you are experiencing
problems."
I checked, the patch from Zope does help. The attached file
contains the patch as applied to django.test._doctest.
Attachments (2)
Change History (6)
by , 18 years ago
| Attachment: | doctest_patch_for_coverage_py.diff added |
|---|
by , 18 years ago
| Attachment: | doctest_patch_for_coverage_py-r6777.diff added |
|---|
comment:1 by , 18 years ago
comment:2 by , 18 years ago
| Triage Stage: | Unreviewed → Ready for checkin |
|---|
comment:3 by , 18 years ago
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
The previous patch doesn't apply cleanly to the current trunk.