From: Kevin Boulain <kevin@boula.in>
To: notmuch@notmuchmail.org
Cc: Kevin Boulain <kevin@boula.in>
Subject: [PATCH v2 5/5] test: add test for notmuch_message_remove_all_properties_with_prefix
Date: Wed, 29 Mar 2023 18:13:33 +0200 [thread overview]
Message-ID: <20230329161333.154904-5-kevin@boula.in> (raw)
In-Reply-To: <87v8ij6ben.fsf@tethera.net>
It wasn't covered, though it shares most of its implementation with
notmuch_message_remove_all_properties.
---
test/T610-message-property.sh | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/test/T610-message-property.sh b/test/T610-message-property.sh
index e4a4b89c..480b04fc 100755
--- a/test/T610-message-property.sh
+++ b/test/T610-message-property.sh
@@ -346,4 +346,19 @@ for (key,val) in msg.get_properties("testkey",True):
EOF
test_expect_equal_file /dev/null OUTPUT
+test_begin_subtest "notmuch_message_remove_all_properties_with_prefix"
+cat c_head - c_tail <<'EOF' | test_C ${MAIL_DIR}
+EXPECT0(notmuch_message_remove_all_properties_with_prefix (message, "testkey3"));
+print_properties (message, "", FALSE);
+EOF
+cat <<'EOF' >EXPECTED
+== stdout ==
+fancy key with áccènts = import value with =
+testkey1 = alice
+testkey1 = bob
+testkey1 = testvalue2
+== stderr ==
+EOF
+test_expect_equal_file EXPECTED OUTPUT
+
test_done\r
next prev parent reply other threads:[~2023-03-29 16:14 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-01 20:51 [PATCH 1/2] test: display key name in property tests Kevin Boulain
2023-03-01 20:51 ` [PATCH 2/2] lib/message-property: sync removed properties to the database Kevin Boulain
2023-03-02 22:39 ` Tomi Ollila
2023-03-02 23:08 ` Kevin Boulain
2023-03-29 11:32 ` David Bremner
2023-03-29 16:13 ` [PATCH v2 1/5] test: display key name in property tests Kevin Boulain
2023-03-29 16:13 ` [PATCH v2 2/5] test: remove unnecessary sorting Kevin Boulain
2023-03-29 16:13 ` [PATCH v2 3/5] test: reorganize tests and mark a few of them as broken Kevin Boulain
2023-03-29 16:13 ` [PATCH v2 4/5] lib/message-property: sync removed properties to the database Kevin Boulain
2023-03-29 16:13 ` Kevin Boulain [this message]
2023-03-30 11:25 ` [PATCH v2 5/5] test: add test for notmuch_message_remove_all_properties_with_prefix David Bremner
2023-03-29 16:23 ` [PATCH 2/2] lib/message-property: sync removed properties to the database Kevin Boulain
2023-03-29 11:33 ` David Bremner
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=20230329161333.154904-5-kevin@boula.in \
--to=kevin@boula.in \
--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).