On Mon, 20 Sep 2010 15:33:09 -0700, Carl Worth <cworth@cworth.org> wrote: > I think what I'd prefer to have is for test-lib.sh to populate a > non-empty database (it could even provide a function to reset the > database to empty for any tests that actually want that). I've now implemented this. I did it slightly differently, making test-lib.sh provide an empty database by default and allowing tests to call a new add_email_corpus function if they need a bunch of email to work with. That's because it turns out that many of the existing tests really do want to focus only on a few, carefully-controlled messages (think about the tests for "notmuch reply" for example). > For efficiency, the non-empty database could be created just once at the > first invocation and then could simply be copied into place for future > invocations. I did do it this efficient way. It's only being used currently by the search and dump-restore tests, so that efficiency doesn't matter too much yet. But I do expect many more tests to start using this functionality soon. -Carl -- carl.d.worth@intel.com