[PATCH 10/10] test: use emacsclient(1) for Emacs tests
Carl Worth
cworth at cworth.org
Tue Jun 28 17:15:42 PDT 2011
On Wed, 29 Jun 2011 02:22:31 +0400, Dmitry Kurochkin <dmitry.kurochkin at gmail.com> wrote:
> Ouch. I never saw these. Do you get these in crypto tests only?
Yes.
I just found the bug. The crypto tests use emacs_deliver_message to
generate signed/encrypted messages, but that function doesn't call
increment_mtime between running emacs and running "notmuch new".
That means that if the emacs_deliver_message code is fast enough, (less
than 1 second), and if the test suite is being run on a lame filesystem
without sub-second timestamp granularity (including ext3fs) that the
"notmuch new" invocation will not see the mail[*].
I've added a call to increment_mtime and the failures go away. So I've
pushed the patch to use emacsclient now.
Thanks very much for helping our test suite run faster!
-Carl
[*] And, yes, this does mean that there are race conditions under which
mail can be delivered and notmuch won't see it, (unless subsequent mails
are delivered to the same directory). Austin has a plan to fix the use
of the mtime timestamp in notmuch, (never storing the current mtime in
the database if it's the same as the current time), that should
hopefully close this race window.
--
carl.d.worth at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20110628/22a8df89/attachment.pgp>
More information about the notmuch
mailing list