Re: Resetting settings under test

2011-05-17 Thread Jannis Leidel
On Tue, May 17, 2011 at 6:42 PM, Jeremy Dunck wrote: > On Tue, May 17, 2011 at 11:01 AM, Jannis Leidel wrote: >>> I was looking more for transaction rollback semantics -- rather than >>> overriding (and then restoring) specific settings, I was hoping for >>> settings to be set back just as they w

Re: Resetting settings under test

2011-05-17 Thread Jeremy Dunck
On Tue, May 17, 2011 at 11:01 AM, Jannis Leidel wrote: >> I was looking more for transaction rollback semantics -- rather than >> overriding (and then restoring) specific settings, I was hoping for >> settings to be set back just as they were before the test. > > Yah, but the good news is that the

Re: Resetting settings under test

2011-05-17 Thread Jannis Leidel
On 17.05.2011, at 17:41, Jeremy Dunck wrote: > On Fri, May 13, 2011 at 10:10 AM, Jannis Leidel wrote: > ... >> I've added something related the other day in changeset 16165. >> > > Following up here, Jannis added a patch to a sort-of related ticket: > http://code.djangoproject.com/ticket/15561

Re: Resetting settings under test

2011-05-17 Thread Jeremy Dunck
On Fri, May 13, 2011 at 10:10 AM, Jannis Leidel wrote: ... > I've added something related the other day in changeset 16165. > Following up here, Jannis added a patch to a sort-of related ticket: http://code.djangoproject.com/ticket/15561 This refactors the context manager into also supporting us

Re: Resetting settings under test

2011-05-13 Thread Jannis Leidel
On 13.05.2011, at 15:52, akaariai wrote: > On May 13, 3:41 pm, Jeremy Dunck wrote: >> In general, the TestCase does a good job of cleaning up the >> environment (resetting the DB, etc.), but I've run across an edge case >> that might be worth putting upstream. >> >> I have a large codebase runn

Re: Resetting settings under test

2011-05-13 Thread akaariai
On May 13, 3:41 pm, Jeremy Dunck wrote: > In general, the TestCase does a good job of cleaning up the > environment (resetting the DB, etc.), but I've run across an edge case > that might be worth putting upstream. > > I have a large codebase running multi-tenant -- lots of sites per WSGI > proces

Resetting settings under test

2011-05-13 Thread Jeremy Dunck
In general, the TestCase does a good job of cleaning up the environment (resetting the DB, etc.), but I've run across an edge case that might be worth putting upstream. I have a large codebase running multi-tenant -- lots of sites per WSGI process, running process-per-request, and it serves those