X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;ds=sidebyside;f=test%2FT035-read-config.sh;h=0aa2e5537ae39296e2220d160c2ff15722e40c26;hb=f994f0e7df178eb31c656329bb28ffa832ac4364;hp=35fbd60043a1b3fa00288052400ac0624f88ad75;hpb=66adcd4f538d426205fd09b0f97b63c74e9e82d7;p=notmuch diff --git a/test/T035-read-config.sh b/test/T035-read-config.sh index 35fbd600..0aa2e553 100755 --- a/test/T035-read-config.sh +++ b/test/T035-read-config.sh @@ -142,4 +142,42 @@ notmuch dump > OUTPUT restore_config test_expect_equal_file EXPECTED OUTPUT +test_begin_subtest "Insert message with custom new.tags (xdg)" +backup_config +xdg_config +tag=test${RANDOM} +notmuch --config=${CONFIG_PATH} config set new.tags $tag +generate_message \ + "[subject]=\"insert-subject\"" \ + "[date]=\"Sat, 01 Jan 2000 12:00:00 -0000\"" \ + "[body]=\"insert-message\"" +mkdir -p ${MAIL_DIR}/{cur,new,tmp} +notmuch insert < "$gen_msg_filename" +notmuch dump id:$gen_msg_id > OUTPUT +cat < EXPECTED +#notmuch-dump batch-tag:3 config,properties,tags ++$tag -- id:$gen_msg_id +EOF +restore_config +test_expect_equal_file EXPECTED OUTPUT + +test_begin_subtest "Insert message with custom new.tags (xdg+profile)" +backup_config +tag=test${RANDOM} +xdg_config $tag +notmuch --config=${CONFIG_PATH} config set new.tags $tag +generate_message \ + "[subject]=\"insert-subject\"" \ + "[date]=\"Sat, 01 Jan 2000 12:00:00 -0000\"" \ + "[body]=\"insert-message\"" +mkdir -p ${MAIL_DIR}/{cur,new,tmp} +notmuch insert < "$gen_msg_filename" +notmuch dump id:$gen_msg_id > OUTPUT +cat < EXPECTED +#notmuch-dump batch-tag:3 config,properties,tags ++$tag -- id:$gen_msg_id +EOF +restore_config +test_expect_equal_file EXPECTED OUTPUT + test_done