mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-25 12:28:09 +01:00
test: test regexp based new.ignore
Just some basics.
This commit is contained in:
parent
f2a6790583
commit
7354d6d8f6
1 changed files with 22 additions and 0 deletions
|
@ -259,6 +259,28 @@ ln -s i_do_not_exist "${MAIL_DIR}"/broken_link
|
||||||
output=$(NOTMUCH_NEW 2>&1)
|
output=$(NOTMUCH_NEW 2>&1)
|
||||||
test_expect_equal "$output" "No new mail."
|
test_expect_equal "$output" "No new mail."
|
||||||
|
|
||||||
|
test_begin_subtest "Ignore files and directories specified in new.ignore (regexp)"
|
||||||
|
notmuch config set new.ignore ".git" "/^bro.*ink\$/" "/ignored.*file/"
|
||||||
|
output=$(NOTMUCH_NEW --debug 2>&1 | sort)
|
||||||
|
test_expect_equal "$output" \
|
||||||
|
"(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/.git
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/.ignored_hidden_file
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/broken_link
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/ignored_file
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/one/ignored_file
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/one/two/ignored_file
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/one/two/three/.git
|
||||||
|
(D) add_files, pass 1: explicitly ignoring ${MAIL_DIR}/one/two/three/ignored_file
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/.git
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/.ignored_hidden_file
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/broken_link
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/ignored_file
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/one/ignored_file
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/one/two/ignored_file
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/one/two/three/.git
|
||||||
|
(D) add_files, pass 2: explicitly ignoring ${MAIL_DIR}/one/two/three/ignored_file
|
||||||
|
No new mail."
|
||||||
|
|
||||||
test_begin_subtest "Quiet: No new mail."
|
test_begin_subtest "Quiet: No new mail."
|
||||||
output=$(NOTMUCH_NEW --quiet)
|
output=$(NOTMUCH_NEW --quiet)
|
||||||
test_expect_equal "$output" ""
|
test_expect_equal "$output" ""
|
||||||
|
|
Loading…
Reference in a new issue