[sqlalchemy] Re: unit testing idioms

2009-07-08 Thread Chris Withers
Mike Orr wrote: You generally want to use a test database rather than depending on a rollback to preserve the live data, because who knows when something might go wrong (e.g.,, a stray commit you didn't notice). True. Although I wonder how fixture (http://code.google.com/p/fixture/)

[sqlalchemy] Re: unit testing idioms

2009-06-30 Thread Mike Orr
On Wed, Jun 24, 2009 at 3:11 PM, Chris Withersch...@simplistix.co.uk wrote: Hi All, I'm wondering what the common idiom is for unit testing w.r.t. data and transactions... So, coming from my ZODB background, in unit tests we usually: - set up the objects required - run the code to be

[sqlalchemy] Re: unit testing idioms

2009-06-29 Thread phrrn...@googlemail.com
From http://code.google.com/p/fixture/, fixture provides several utilities for achieving a fixed state when testing Python programs. Specifically, these utilities setup / teardown databases and work with temporary file systems. On Jun 27, 3:14 pm, Chris Withers ch...@simplistix.co.uk wrote:

[sqlalchemy] Re: unit testing idioms

2009-06-27 Thread Chris Withers
phrrn...@googlemail.com wrote: I am learning fixtures right now to see if I can use it to successfully solve this problem. What is fixtures? Chris -- Simplistix - Content Management, Zope Python Consulting - http://www.simplistix.co.uk

[sqlalchemy] Re: unit testing idioms

2009-06-26 Thread phrrn...@googlemail.com
I am learning fixtures right now to see if I can use it to successfully solve this problem. pjjH On Jun 24, 6:11 pm, Chris Withers ch...@simplistix.co.uk wrote: Hi All, I'm wondering what the common idiom is for unit testing w.r.t. data and transactions... So, coming from my ZODB