From 8bf331108458591a36d11487cea39282c9b5bc0d Mon Sep 17 00:00:00 2001 From: David Bremner Date: Fri, 7 May 2021 07:56:08 -0300 Subject: [PATCH] test: test explicit configuration of backup directory Including the relative path that was broken until a recent commit. --- test/T530-upgrade.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/test/T530-upgrade.sh b/test/T530-upgrade.sh index cce29f45..5f0de2ed 100755 --- a/test/T530-upgrade.sh +++ b/test/T530-upgrade.sh @@ -54,4 +54,23 @@ for key in 'from/subject/message-ID in database' \ restore_database done +test_begin_subtest "upgrade with configured backup dir" +notmuch config set database.backup_dir ${HOME}/backups +delete_feature 'modification tracking' +notmuch new | grep Backing | notmuch_dir_sanitize | sed 's/dump-[0-9T]*/dump-XXX/' > OUTPUT +cat < EXPECTED +Backing up tags to CWD/home/backups/dump-XXX.gz... +EOF +test_expect_equal_file EXPECTED OUTPUT + +test_begin_subtest "upgrade with relative configured backup dir" +notmuch config set database.backup_dir ${HOME}/backups +delete_feature 'modification tracking' +notmuch new | grep Backing | notmuch_dir_sanitize | sed 's/dump-[0-9T]*/dump-XXX/' > OUTPUT +cat < EXPECTED +Backing up tags to CWD/home/backups/dump-XXX.gz... +EOF +test_expect_equal_file EXPECTED OUTPUT + + test_done