unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH 1/2] test/libconfig: save and restore config file
@ 2021-12-11 12:49 David Bremner
  2021-12-11 12:49 ` [PATCH 2/2] test/libconfig: add two tests for the config = "" case David Bremner
  2022-01-16  1:56 ` [PATCH 1/2] test/libconfig: save and restore config file David Bremner
  0 siblings, 2 replies; 7+ messages in thread
From: David Bremner @ 2021-12-11 12:49 UTC (permalink / raw)
  To: notmuch

Currently the config file is unusable for further tests requiring a
valid database path.
---
 test/T590-libconfig.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/test/T590-libconfig.sh b/test/T590-libconfig.sh
index eb303444..089b4e58 100755
--- a/test/T590-libconfig.sh
+++ b/test/T590-libconfig.sh
@@ -972,6 +972,7 @@ EOF
 test_expect_equal_file EXPECTED OUTPUT
 
 test_begin_subtest "open: database parameter overrides implicit config"
+cp $NOTMUCH_CONFIG ${NOTMUCH_CONFIG}.bak
 notmuch config set database.path ${MAIL_DIR}/nonexistent
 cat c_head3 - c_tail3 <<'EOF' | test_C ${MAIL_DIR}
   const char *path = NULL;
@@ -982,6 +983,7 @@ cat c_head3 - c_tail3 <<'EOF' | test_C ${MAIL_DIR}
   path = notmuch_database_get_path (db);
   printf ("path: %s\n", path ? path : "(null)");
 EOF
+cp ${NOTMUCH_CONFIG}.bak ${NOTMUCH_CONFIG}
 cat <<EOF> EXPECTED
 == stdout ==
 status: 0
-- 
2.33.0

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-01-16  1:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-11 12:49 [PATCH 1/2] test/libconfig: save and restore config file David Bremner
2021-12-11 12:49 ` [PATCH 2/2] test/libconfig: add two tests for the config = "" case David Bremner
2021-12-25 13:33   ` [PATCH 3/6] lib/open: use db struct as talloc ctx for choose_database_path David Bremner
2021-12-25 13:33     ` [PATCH 4/6] lib/open: use notmuch->params to track split status David Bremner
2021-12-25 13:33     ` [PATCH 5/6] lib/config: make sure the config map exists when loading defaults David Bremner
2021-12-25 13:33     ` [PATCH 6/6] lib/open: no default mail root in split configurations David Bremner
2022-01-16  1:56 ` [PATCH 1/2] test/libconfig: save and restore config file David Bremner

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).