Syncing strategy

Sebastian Spaeth Sebastian at SSpaeth.de
Thu Dec 9 19:42:07 GMT 2010


On Thu, 09 Dec 2010 19:54:13 +0100, Sebastian Spaeth <Sebastian at SSpaeth.de> wrote:
> - I want to create the Maildir Scaffold *once* when i start maildir
>   tests and rip it down after all the tests have run. However, the
>   TestCase class runs setUp() and tearDown() for each single test,
>   making it unsuitable. It also runs testCase.__init__ and __del__ for
>   each test, making that unusable too. What I need and what are the
>   TestCase.setUpClass() and tearDownClass() functions, which are run
>   exactly once at the beginning and the end of all tests in a TestCase.
>   However, that is only available on python 2.7. :-(.
> 
>   So I fudge now and call test2 at the end of test1, which let's
>   everything appear as a single case. This needs to be investigated how
>   it can be solved in a neat way.

I solved this just now and pushed a new version which is able to cleanly
run tests. :-) More tests are welcome.

Sebastian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://alioth-lists.debian.net/pipermail/offlineimap-project/attachments/20101209/2c259c19/attachment-0001.sig>


More information about the OfflineIMAP-project mailing list