Opened 16 years ago

Closed 16 years ago

Last modified 13 years ago

#7825 closed (fixed)

modeltests/delete test fails after NFA merge

Reported by: Jacob Owned by: Luke Plant
Component: Metasystem Version: dev
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

After the NFA merge, this happens:

======================================================================
FAIL: Doctest: modeltests.delete.models.__test__.API_TESTS
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/jacob/Projects/Django/upstream/django/test/_doctest.py", line 2180, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for modeltests.delete.models.__test__.API_TESTS
  File "/Users/jacob/Projects/Django/upstream/tests/modeltests/delete/models.py", line unknown line number, in API_TESTS

----------------------------------------------------------------------
File "/Users/jacob/Projects/Django/upstream/tests/modeltests/delete/models.py", line ?, in modeltests.delete.models.__test__.API_TESTS
Failed example:
    del D._meta._related_objects_cache
Exception raised:
    Traceback (most recent call last):
      File "/Users/jacob/Projects/Django/upstream/django/test/_doctest.py", line 1267, in __run
        compileflags, 1) in test.globs
      File "<doctest modeltests.delete.models.__test__.API_TESTS[17]>", line 1, in <module>
        del D._meta._related_objects_cache
    AttributeError: _related_objects_cache


----------------------------------------------------------------------
Ran 1 test in 0.046s

FAILED (failures=1)

It appears to be related to the somewhat fishy internals hacking in the test case. The failure may be related to the change in import behavior because of admin registry class.

Change History (4)

comment:1 by Brian Rosner, 16 years ago

This started to appear prior to the merge on the newforms-admin branch once I committed [7929].

comment:2 by anonymous, 16 years ago

[8:13pm] jbronn: regarding #7825, when I merge up to latest trunk the delte test pass; so I examined the differences between the two branches.
[8:14pm] jbronn: besides the stuff that was supposed to be different, I found some vestiges that I need to remove -- one of those was the 'NoField' stuff used by the ManyToMany field. when I remove those references the test fails like in trunk

comment:3 by Luke Plant, 16 years ago

Resolution: fixed
Status: newclosed

(In [8030]) Fixed #7825 - modeltests/delete tests failing after NFA merge, and improved documentation of these tests.

comment:4 by Jacob, 13 years ago

milestone: 1.0 alpha

Milestone 1.0 alpha deleted

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