Opened 12 years ago

Closed 11 years ago

Last modified 10 years ago

#17366 closed Cleanup/optimization (fixed)

Deprecate loading tests from models.py

Reported by: Alex Gaynor Owned by: jcatalan
Component: Testing framework Version: dev
Severity: Normal 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

This is inconsistent with pretty much every other test tool, and really doesn't make a whole lot of sense.

Change History (9)

comment:1 by Russell Keith-Magee, 12 years ago

There is a reason that models.py was searched for tests -- it's to catch any doctests that are defined on model methods.

I'm not necessarily arguing against the decision to deprecate models.py as a source of tests, but given that it wasn't a completely arbitrary decision in the first place, it's worth documenting the specific consequences.

comment:2 by EmilStenstrom, 11 years ago

Component: Testing frameworkDocumentation

comment:3 by Tim Graham, 11 years ago

I don't think this should be a documentation ticket as its scope is much larger than just that, correct?

comment:4 by Aymeric Augustin, 11 years ago

Component: DocumentationTesting framework

comment:5 by jcatalan, 11 years ago

Owner: changed from nobody to jcatalan
Status: newassigned

comment:6 by Carl Meyer <carl@…>, 11 years ago

Resolution: fixed
Status: assignedclosed

In 9012833af857e081b515ce760685b157638efcef:

Fixed #17365, #17366, #18727 -- Switched to discovery test runner.

Thanks to Preston Timmons for the bulk of the work on the patch, especially
updating Django's own test suite to comply with the requirements of the new
runner. Thanks also to Jannis Leidel and Mahdi Yusuf for earlier work on the
patch and the discovery runner.

Refs #11077, #17032, and #18670.

comment:7 by Florian Apolloner <florian@…>, 11 years ago

In e23a5f9a4730ddecb8f3950ee2936716f458c506:

Fixed a regression in the test runner loading of runtests.py.

Refs #17365, #17366, #18727.

comment:8 by Florian Apolloner <florian@…>, 11 years ago

In 2bf403ecbd958bfb269794b36e61b69f0aede4cf:

Fixed a regression from e23a5f9a4730ddecb8f3950ee2936716f458c506.

Excluded postgis specific gis tests from other spatial databases.

Refs #17365, #17366, #18727.

comment:9 by Tim Graham <timograham@…>, 10 years ago

In bf5430a20b65b3e76a2f8cd2580101e0baa59f82:

Removed django.test.simple and django.test._doctest per deprecation timeline.

refs #17365, #17366, #18727.

Note: See TracTickets for help on using tickets.
Back to Top