From: Pieter Praet <pieter@praet.org>
To: notmuch@notmuchmail.org
Subject: Re: [PATCH] test: "search-by-folder" single-word search terms should be updated correctly when directories are renamed.
Date: Thu, 12 May 2011 15:22:25 +0200 [thread overview]
Message-ID: <8739kk9hpq.fsf@praet.org> (raw)
In-Reply-To: <877hc3x5td.fsf@A7GMS.i-did-not-set--mail-host-address--so-tickle-me>
On Sun, 13 Mar 2011 00:44:14 +0100, Pieter Praet <pieter@praet.org> wrote:
> On Mon, 17 Jan 2011 14:00:41 +0100, Sebastian Spaeth <Sebastian@SSpaeth.de> wrote:
> > However, when moving files into another folder and rerunning notmuch
> > new, the folder value is never updated, it seems.
>
> This appears to occur only when searching with a single-word folder
> path.
>
> ---
> test/search-by-folder | 6 +++++-
> 1 files changed, 5 insertions(+), 1 deletions(-)
>
> diff --git a/test/search-by-folder b/test/search-by-folder
> index 162158c..63ed57b 100755
> --- a/test/search-by-folder
> +++ b/test/search-by-folder
> @@ -28,13 +28,17 @@ notmuch new
> output=$(notmuch search folder:bad/news | notmuch_search_sanitize)
> test_expect_equal "$output" "thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; Bears (inbox unread)"
>
> -test_begin_subtest "After rename, old path returns nothing"
> +test_begin_subtest "After rename, old multi-word path returns nothing"
> mv "${MAIL_DIR}/duplicate/bad/news" "${MAIL_DIR}/duplicate/bad/olds"
> increment_mtime "${MAIL_DIR}/duplicate/bad"
> notmuch new
> output=$(notmuch search folder:bad/news | notmuch_search_sanitize)
> test_expect_equal "$output" ""
>
> +test_begin_subtest "After rename, old single-word path returns nothing"
> +output=$(notmuch search folder:news | notmuch_search_sanitize)
> +test_expect_equal "$output" ""
> +
> test_begin_subtest "After rename, new path returns result"
> output=$(notmuch search folder:bad/olds | notmuch_search_sanitize)
> test_expect_equal "$output" "thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; Bears (inbox unread)"
> ---
I've pushed a cleaner version of this patch to my github repo, for
inclusion in release-candidate/0.6.
Peace
[0] git://github.com/praet/notmuch.git
for-review/test-folder-search
da50c58545c2fbb77fed
--
Pieter
next prev parent reply other threads:[~2011-05-12 13:22 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-15 22:46 Folder-based searching Carl Worth
2011-01-17 6:17 ` Xavier Maillard
2011-01-17 12:43 ` Sebastian Spaeth
2011-01-17 13:00 ` Sebastian Spaeth
2011-03-12 23:44 ` [PATCH] test: "search-by-folder" single-word search terms should be updated correctly when directories are renamed Pieter Praet
2011-05-12 13:22 ` Pieter Praet [this message]
2011-05-12 16:04 ` Jameson Graef Rollins
2011-05-13 8:06 ` [PATCH] test: do folder-based search with a single-term path after moving message Pieter Praet
2011-01-17 18:48 ` Folder-based searching Rob Browning
2011-01-18 19:09 ` Carl Worth
2011-01-18 19:54 ` Rob Browning
2011-01-18 20:16 ` Carl Worth
2011-01-19 7:29 ` Austin Clements
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8739kk9hpq.fsf@praet.org \
--to=pieter@praet.org \
--cc=notmuch@notmuchmail.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).