<feed xmlns='http://www.w3.org/2005/Atom'>
<title>notmuch/test/test-lib.el, branch 0.20.1</title>
<subtitle>thread-based email index, search, and tagging</subtitle>
<id>https://git.notmuchmail.org/git/notmuch/atom?h=0.20.1</id>
<link rel='self' href='https://git.notmuchmail.org/git/notmuch/atom?h=0.20.1'/>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/'/>
<updated>2014-09-21T19:23:45Z</updated>
<entry>
<title>test: New tests for Emacs charset handling</title>
<updated>2014-09-21T19:23:45Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@MIT.EDU</email>
</author>
<published>2014-04-21T18:37:39Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=f4cdabccd0e75d94d7f6f4d50684afc67bbf7f0d'/>
<id>urn:sha1:f4cdabccd0e75d94d7f6f4d50684afc67bbf7f0d</id>
<content type='text'>
The test of viewing 8bit messages is known-broken.  The rest pass, but
for very fragile reasons.  The next several commits will fix the
known-broken test and make our charset handling robust.
</content>
</entry>
<entry>
<title>test/emacs: globally force the html renderer to html2text</title>
<updated>2014-09-21T19:12:52Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2014-09-20T05:41:35Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=b4892677016c7a994dea75b8ea71bbde92ac17cb'/>
<id>urn:sha1:b4892677016c7a994dea75b8ea71bbde92ac17cb</id>
<content type='text'>
Previously we did this for a single test, but some other proposed
tests ( id:1398105468-14317-3-git-send-email-amdragon@mit.edu ) show
similar breakage when switching renderers.
</content>
</entry>
<entry>
<title>test: make test_emacs call post-command-hook</title>
<updated>2014-07-13T15:33:53Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2014-05-09T00:20:07Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=eed6c75556e18d943ac690598edceef0c4ee59d5'/>
<id>urn:sha1:eed6c75556e18d943ac690598edceef0c4ee59d5</id>
<content type='text'>
The unread/read changes will use the post-command-hook. test_emacs
does not call the post-command-hook. This adds a notmuch-test-progn
which takes a list of commands as argument and executes them in turn
but runs the post-command-hook after each one.

The caller can batch operations (ie to stop post-command-hook from
being interleaved) by wrapping the batch of operations inside a progn.

We also explicitly run the post-command-hook before getting the output
from a test; this makes sense as this will be a place the user would
be seeing the information.
</content>
</entry>
<entry>
<title>emacs: show: mark tags changed since buffer loaded</title>
<updated>2014-03-24T22:48:04Z</updated>
<author>
<name>Mark Walters</name>
<email>markwalters1009@gmail.com</email>
</author>
<published>2014-03-22T11:51:09Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=941e172724188eb0f65bc05035a0a6871a70ba72'/>
<id>urn:sha1:941e172724188eb0f65bc05035a0a6871a70ba72</id>
<content type='text'>
This allows (and requires) the original-tags to be passed along with
the current-tags to be passed to notmuch-tag-format-tags. This allows
the tag formatting to show added and deleted tags.By default a removed
tag is displayed with strike-through in red (if strike-through is not
available, eg on a terminal, inverse video is used instead) and an
added tag is displayed underlined in green.

If the caller does not wish to use the new feature it can pass
current-tags for both arguments and, at this point, we do exactly that
in the three callers of this function.

Note, we cannot tidily allow original-tags to be optional because we would
need to distinguish nil meaning "we are not specifying original-tags"
from nil meaning there were no original-tags (an empty list).

We use this in subsequent patches to make it clear when a message was
unread when you first loaded a show buffer (previously the unread tag
could be removed before a user realised that it had been unread).

The code adds into the existing tag formatting code. The user can
specify exactly how a tag should be displayed normally, when deleted,
or when added.

Since the formatting code matches regexps a user can match all deleted
tags with a ".*" in notmuch-tag-deleted-formats.  For example setting
notmuch-tag-deleted-formats to '((".*" nil)) tells notmuch not to show
deleted tags at all.

All the variables are customizable; however, more complicated cases
like changing the face depending on the type of display will require
custom lisp.

Currently this overrides notmuch-tag-deleted-formats for the tests
setting it to '((".*" nil)) so that they get removed from the display
and, thus, all tests still pass.
</content>
</entry>
<entry>
<title>test/emacs: replace the use of process-attributes with signal-process</title>
<updated>2014-01-12T21:08:14Z</updated>
<author>
<name>David Bremner</name>
<email>david@tethera.net</email>
</author>
<published>2014-01-11T17:25:39Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=b4f3be53c8789485d63aafde03b5f5a7e5d86592'/>
<id>urn:sha1:b4f3be53c8789485d63aafde03b5f5a7e5d86592</id>
<content type='text'>
In some environments (at least Hurd), process-attributes is
unimplimented and always returns nil.  This ends up causing test
failures (see e.g. id:87a9ffofsc.fsf@zancas.localnet).

Historically and according to POSIX 1003.1-2001, a signal of 0 can be
used to check the validity of a pid. This seems less heinous than
parsing the output of ps(1).
</content>
</entry>
<entry>
<title>test: delay watchdog checks in emacs.</title>
<updated>2013-01-29T23:17:07Z</updated>
<author>
<name>David Bremner</name>
<email>bremner@debian.org</email>
</author>
<published>2013-01-29T23:06:37Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=f021a062888b7940fe7ee049a88ae176837bcd96'/>
<id>urn:sha1:f021a062888b7940fe7ee049a88ae176837bcd96</id>
<content type='text'>
Instead of checking immediately for the watched process, delay a
minute, or in the case that process-attributes returns nil, for two
minutes.  This is intended to cope with the case that
process-attributes is unimplimented, and returns always returns nil.
In this case, the watchdog check is the same as the two minute limit
imposed by timeout.
</content>
</entry>
<entry>
<title>test: Test buttonization of id: links</title>
<updated>2012-11-15T22:03:02Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@MIT.EDU</email>
</author>
<published>2012-11-15T19:49:52Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=65801835ee47dc4cada82c8a3ae16e8177a7919a'/>
<id>urn:sha1:65801835ee47dc4cada82c8a3ae16e8177a7919a</id>
<content type='text'>
This matches the current behavior of the buttonizer, so it passes, but
many of these cases are not what you'd want (and some of them aren't
even valid Xapian queries).  The next patch will fix the handling of
these cases and update the test.
</content>
</entry>
<entry>
<title>test: emacs: run list-processes after accept-process-output in emacs 23.1</title>
<updated>2012-08-29T22:06:18Z</updated>
<author>
<name>Tomi Ollila</name>
<email>tomi.ollila@iki.fi</email>
</author>
<published>2012-08-05T11:13:02Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=3c053bf81cf75ab37b906e748ea1edcf8af4b178'/>
<id>urn:sha1:3c053bf81cf75ab37b906e748ea1edcf8af4b178</id>
<content type='text'>
When running emacs tests using emacs 23.1.1 the tests block (until timeout)
when emacs function (notmuch-test-wait) is called.

There is an emacs bug #2930 titled:
23.0.92; `accept-process-output' and `sleep-for' do not run sentinel

It seems this is present in emacs 23.1.

Calling list-processes after accept-process-output seems work around
this problem; in case Emacs version is 23.1 a defadvice is activated
to do just that.
</content>
</entry>
<entry>
<title>test: emacs: call accept-process-output in notmuch-test-wait</title>
<updated>2012-08-29T22:06:07Z</updated>
<author>
<name>Tomi Ollila</name>
<email>tomi.ollila@iki.fi</email>
</author>
<published>2012-08-05T11:13:01Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=f791cc9247dfac8640c8896bad9d9c1a1e70edfc'/>
<id>urn:sha1:f791cc9247dfac8640c8896bad9d9c1a1e70edfc</id>
<content type='text'>
notmuch-test-wait called sleep-for in a loop to wait unconditionally 0.1
seconds while waiting for process to exit.
accept-process-output returns as soon as there is any data available
from process, so using it avoids unnecessary fixed delays.
Both of these functions run process sentinels.
</content>
</entry>
<entry>
<title>test: New test for incremental search output parsing</title>
<updated>2012-07-12T23:39:18Z</updated>
<author>
<name>Austin Clements</name>
<email>amdragon@MIT.EDU</email>
</author>
<published>2012-07-09T21:42:39Z</published>
<link rel='alternate' type='text/html' href='https://git.notmuchmail.org/git/notmuch/commit/?id=f94a50d80af8c2a5513e58db954dd0b1910eb4a8'/>
<id>urn:sha1:f94a50d80af8c2a5513e58db954dd0b1910eb4a8</id>
<content type='text'>
This advises the search process filter to make it process one
character at a time in order to test the pessimal case for incremental
search output parsing.

The text parser fails this test because it gets tricked into thinking
a parenthetical remark in a subject is the tag list.
</content>
</entry>
</feed>
