On Tue, 2007-05-29 at 00:30 +0200, Sandro Dentella wrote: > On Mon, May 28, 2007 at 04:26:17PM -0500, Jeremy Dunck wrote: > > > > On 5/28/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > > > Okay... time to fix that problem then. Probably need to introduce a > > > settings for tests only for database encoding. I should have done that > > > when I first saw the problem instead of trying to dodge around it. > > Do we need such a settings or we really need to *copy* database encoding so > that tests are done exactly as the application database. (if it's possible > to use other than utf8...).
That assumes there is an application database to copy and/or that is configured sensibly. It's a bit of a wart that DATABASE_NAME is required at all in the test settings file -- it's just that it's woven pretty deeply into various places in the code. For fun, somebody could look into fixing that; it would only take an hour or so for somebody with reasonable Pyhthon familiarity and not much Django internals familiarity, I would guess. Short verison: tests should be as independent and run in as uniform an environment as possible. > That would prevent people from runnnig wanderfull tests on a well configured > db when the real db is still "SQL_ASCII" just becouse template1 was shipped > that way! The test framework can't realistically insulate people against mistakes they make outside of Django. You create test databases much more often than project databases (unless you don't run your tests). So I'm -1 on trying to do anything like this. Regards, Malcolm --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---