diff options
| author | Yuri Volchkov <yuri.volchkov@gmail.com> | 2017-08-21 17:44:46 +0200 |
|---|---|---|
| committer | David Bremner <david@tethera.net> | 2017-08-22 18:48:09 -0300 |
| commit | 33a170e1163b39b47deafcaef863d19c0d5d62cd (patch) | |
| tree | aafd44f9044347d97db33dd2a6ce4f4ecbaac132 /test/T070-insert.sh | |
| parent | cec4a87539599e7d253b694c2a0a81de86d6eb7e (diff) | |
insert: strip trailing / in folder path
This patch fixes the "Insert message into folder with trailing /"
test. The problem was insufficient path canonization.
From database's point of view, "Sent" and "Sent/" are different
folders. If user runs (note the last '/'):
notmuch insert --folder=maildir/Sent/ < test.msg
notmuch will create an extra XDIRECTORY record for the folder
'Sent/'. This means that database will have _TWO_ records for _ONE_
physical folder: 'Sent' and 'Sent/'. However, the 'notmuch new'
command will update only records related to the first one (the correct
one).
Now, if user moved the email file (e.g. from 'Sent/new' to
'Sent/cur'), 'notmuch new' will add a record about the new file, but
will not delete the old record.
Signed-off-by: Yuri Volchkov <yuri.volchkov@gmail.com>
Diffstat (limited to 'test/T070-insert.sh')
| -rwxr-xr-x | test/T070-insert.sh | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/test/T070-insert.sh b/test/T070-insert.sh index 187dfd37..380934a6 100755 --- a/test/T070-insert.sh +++ b/test/T070-insert.sh @@ -133,7 +133,6 @@ dirname=$(dirname "$output") test_expect_equal "$dirname" "$MAIL_DIR/Drafts/new" test_begin_subtest "Insert message into folder with trailing /" -test_subtest_known_broken gen_insert_msg notmuch insert --folder=Drafts/ < "$gen_msg_filename" output=$(notmuch search --output=files id:${gen_msg_id}) |
