#4371: fixture loading fails silently in testcases
-----------------------------------------------------+----------------------
Reporter: John Shaffer <[EMAIL PROTECTED]> | Owner: keithb
Status: new | Component:
Unit test system
Version: SVN | Resolution:
Keywords: fixtures sprintsept14 | Stage:
Accepted
Has_patch: 1 | Needs_docs: 0
Needs_tests: 0 | Needs_better_patch: 1
-----------------------------------------------------+----------------------
Changes (by russellm):
* needs_better_patch: 0 => 1
Comment:
This is close, but not quite ready. In particular, the 'empty' error
handling isn't quite right (or at least, is only one of a possible kind of
error). The original case (3) that I gave isn't covered by your tests; I
suspect all that is required is to move the 'if empty' check one level
less of indentation, so that you are checking if any objects have been
installed for a given fixture name, rather than checking if a specific
file has no objects in it.
Some other minor nitpicks:
- could you please produce diffs from the root directory, rather than at
the file level
- The test case should really be in the regression tests, not the model
tests. The test doesn't serve any real documenation purpose; it is only to
validate that the error conditions are correctly caught.
--
Ticket URL: <http://code.djangoproject.com/ticket/4371#comment:6>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---