Hey, I have a problem similar to this one (click).
Approx 2 hours ago Django stopped running my tests. And I have no idea why. I did some refactoring, then got an ImportError and after I reverted the file, Django stopped running any of my tests. I already deleted all the *.pyc files but nothing changed.
The situation:
I organize all my tests in a sperate test-package. The structure is the following:
/app
/tests
/model
__init__.py
...
__init__.py
...
The __init__.py files define a suite() method that will return all the tests inside the packages like this:
def suite():
suite = TestSuite()
suite.addTest(model.suite())
suite.addTest(user.suite())
return suite
I tried to debug and set a breakpoint in the topmost __init__.py file in the test-package but this breakpoint is never reached.
Any ideas what I am missing?
Ha.. Now I found the error.
The problem was, that I ONLY thought I fixed all ImportErrors. When I started a shell using
manage.py shelland then tried to import the tests-package I saw some other ImportErrors. Fixed them and now the tests are running again.Wished the testrunner would have indicated that something went wrong!