Re: [PATCH 1/4] test: insert into the folder with trailing /

2017-08-20 Thread David Bremner
Yuri Volchkov  writes:

> From database's point of view, "Drafts" and "Drafts/" are different
> folders
>
> Signed-off-by: Yuri Volchkov 

Merged this test, marked as known-broken
___
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch


Re: [PATCH 1/4] test: insert into the folder with trailing /

2017-08-16 Thread David Bremner
Yuri Volchkov  writes:

> From database's point of view, "Drafts" and "Drafts/" are different
> folders
>
> Signed-off-by: Yuri Volchkov 
> ---
>  test/T070-insert.sh | 7 +++
>  1 file changed, 7 insertions(+)
>
> diff --git a/test/T070-insert.sh b/test/T070-insert.sh
> index 48f212e..380934a 100755
> --- a/test/T070-insert.sh
> +++ b/test/T070-insert.sh
> @@ -132,6 +132,13 @@ output=$(notmuch search --output=files path:Drafts/new)
>  dirname=$(dirname "$output")
>  test_expect_equal "$dirname" "$MAIL_DIR/Drafts/new"
>  
> +test_begin_subtest "Insert message into folder with trailing /"
> +gen_insert_msg
> +notmuch insert --folder=Drafts/ < "$gen_msg_filename"
> +output=$(notmuch search --output=files id:${gen_msg_id})
> +dirname=$(dirname "$output")
> +test_expect_equal "$dirname" "$MAIL_DIR/Drafts/new"
> +

This is basically OK, but for future reference you can add
'test_subtest_known_broken' when adding a test, and remove it in the
patch providing a fix. The preserves the nice property that the test
suite passes after every commit.

d
___
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch


[PATCH 1/4] test: insert into the folder with trailing /

2017-08-12 Thread Yuri Volchkov
From database's point of view, "Drafts" and "Drafts/" are different
folders

Signed-off-by: Yuri Volchkov 
---
 test/T070-insert.sh | 7 +++
 1 file changed, 7 insertions(+)

diff --git a/test/T070-insert.sh b/test/T070-insert.sh
index 48f212e..380934a 100755
--- a/test/T070-insert.sh
+++ b/test/T070-insert.sh
@@ -132,6 +132,13 @@ output=$(notmuch search --output=files path:Drafts/new)
 dirname=$(dirname "$output")
 test_expect_equal "$dirname" "$MAIL_DIR/Drafts/new"
 
+test_begin_subtest "Insert message into folder with trailing /"
+gen_insert_msg
+notmuch insert --folder=Drafts/ < "$gen_msg_filename"
+output=$(notmuch search --output=files id:${gen_msg_id})
+dirname=$(dirname "$output")
+test_expect_equal "$dirname" "$MAIL_DIR/Drafts/new"
+
 test_begin_subtest "Insert message into folder, add/remove tags"
 gen_insert_msg
 notmuch insert --folder=Drafts +draft -unread < "$gen_msg_filename"
-- 
2.7.4

___
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch