On Mon, Jul 20, 2009 at 9:45 PM, Andrew Fong<[email protected]> wrote: > > Hi all, > > I'm working on a tweak to django.test.TestCase, my first attempt at > contributing to Django. I've been searching for existing tests of > django.test.TestCase (not tests that use django.test.TestCase, but a > test that verifies the TestCase class itself is working properly), and > haven't been able to locate them. Any pointers on where I can find > these? Or do they not exist?
There are some tests for TestCase, but they're mostly testing the assertions and tools of that nature - i.e., checking that 'assertContains' etc work correctly. There isn't much by way of testing of the setup/teardown logic of TestCase itself. This is partly historical. The original Django TestCase really didn't do much other than install fixtures and construct a test client. Once you can see that a fixture is available in a testcase and you can invoke the test client, there isn't really much more to test. Since then, TestCase has become more complex, and it has become mostly a bootstrapping issue - what do you use to test the tests for TestCase? :-) Any suggestions on how to improve the rigor of this part of Django are most welcome. >From a procedural point of view - if you're working on modifications to TestCase (I'm guessing you're working on the caching thing) this is one of those rare situations where a patch might be accepted into Django without an accompanying test case. If the logic is sufficiently obvious and can be eyeballed correct, and the full test suite passes after applying your patch, then that will probably be sufficient to get your patch into trunk. Yours, Russ Magee %-) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" 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-developers?hl=en -~----------~----~----~----~------~----~------~--~---
