unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH 1/3] test: replace deprecated use of notmuch_database_open_verbose
@ 2022-05-21 18:06 David Bremner
  2022-05-21 18:06 ` [PATCH 2/3] test: replace deprecated use of notmuch_database_open David Bremner
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: David Bremner @ 2022-05-21 18:06 UTC (permalink / raw)
  To: notmuch

We need to do it some day, and it is a bit annoying to read
deprecation messages in broken tests.
---
 test/T560-lib-error.sh     | 4 +++-
 test/T562-lib-database.sh  | 4 +++-
 test/T563-lib-directory.sh | 4 +++-
 test/T564-lib-query.sh     | 4 +++-
 test/T566-lib-message.sh   | 4 +++-
 test/T568-lib-thread.sh    | 4 +++-
 6 files changed, 18 insertions(+), 6 deletions(-)

diff --git a/test/T560-lib-error.sh b/test/T560-lib-error.sh
index 1f4482cb..1d45dc7d 100755
--- a/test/T560-lib-error.sh
+++ b/test/T560-lib-error.sh
@@ -206,7 +206,9 @@ int main (int argc, char** argv)
    char *msg = NULL;
    int fd;
 
-   stat = notmuch_database_open_verbose (argv[1], NOTMUCH_DATABASE_MODE_READ_WRITE, &db, &msg);
+   stat = notmuch_database_open_with_config (argv[1],
+					     NOTMUCH_DATABASE_MODE_READ_WRITE,
+					     NULL, NULL, &db, &msg);
    if (stat != NOTMUCH_STATUS_SUCCESS) {
      fprintf (stderr, "error opening database: %d %s\n", stat, msg ? msg : "");
      exit (1);
diff --git a/test/T562-lib-database.sh b/test/T562-lib-database.sh
index 2314efd2..64233c37 100755
--- a/test/T562-lib-database.sh
+++ b/test/T562-lib-database.sh
@@ -17,7 +17,9 @@ int main (int argc, char** argv)
    notmuch_status_t stat = NOTMUCH_STATUS_SUCCESS;
    char *msg = NULL;
 
-   stat = notmuch_database_open_verbose (argv[1], NOTMUCH_DATABASE_MODE_READ_WRITE, &db, &msg);
+   stat = notmuch_database_open_with_config (argv[1],
+					     NOTMUCH_DATABASE_MODE_READ_WRITE,
+					     NULL, NULL, &db, &msg);
    if (stat != NOTMUCH_STATUS_SUCCESS) {
      fprintf (stderr, "error opening database: %d %s\n", stat, msg ? msg : "");
      exit (1);
diff --git a/test/T563-lib-directory.sh b/test/T563-lib-directory.sh
index ebd7fcb2..22b9e0b9 100755
--- a/test/T563-lib-directory.sh
+++ b/test/T563-lib-directory.sh
@@ -18,7 +18,9 @@ int main (int argc, char** argv)
    notmuch_status_t stat = NOTMUCH_STATUS_SUCCESS;
    char *msg = NULL;
 
-   stat = notmuch_database_open_verbose (argv[1], NOTMUCH_DATABASE_MODE_READ_WRITE, &db, &msg);
+   stat = notmuch_database_open_with_config (argv[1],
+					     NOTMUCH_DATABASE_MODE_READ_WRITE,
+					     NULL, NULL, &db, &msg);
    if (stat != NOTMUCH_STATUS_SUCCESS) {
      fprintf (stderr, "error opening database: %d %s\n", stat, msg ? msg : "");
      exit (1);
diff --git a/test/T564-lib-query.sh b/test/T564-lib-query.sh
index ff1d4984..53a63bf6 100755
--- a/test/T564-lib-query.sh
+++ b/test/T564-lib-query.sh
@@ -17,7 +17,9 @@ int main (int argc, char** argv)
    notmuch_status_t stat;
    char *msg = NULL;
 
-   stat = notmuch_database_open_verbose (argv[1], NOTMUCH_DATABASE_MODE_READ_WRITE, &db, &msg);
+   stat = notmuch_database_open_with_config (argv[1],
+					     NOTMUCH_DATABASE_MODE_READ_WRITE,
+					     NULL, NULL, &db, &msg);
    if (stat != NOTMUCH_STATUS_SUCCESS) {
      fprintf (stderr, "error opening database: %d %s\n", stat, msg ? msg : "");
      exit (1);
diff --git a/test/T566-lib-message.sh b/test/T566-lib-message.sh
index 8b61d182..b6a9e536 100755
--- a/test/T566-lib-message.sh
+++ b/test/T566-lib-message.sh
@@ -29,7 +29,9 @@ int main (int argc, char** argv)
    notmuch_message_t *message = NULL;
    const char *id = "1258471718-6781-1-git-send-email-dottedmag@dottedmag.net";
 
-   stat = notmuch_database_open_verbose (argv[1], NOTMUCH_DATABASE_MODE_READ_WRITE, &db, &msg);
+   stat = notmuch_database_open_with_config (argv[1],
+					     NOTMUCH_DATABASE_MODE_READ_WRITE,
+					     NULL, NULL, &db, &msg);
    if (stat != NOTMUCH_STATUS_SUCCESS) {
      fprintf (stderr, "error opening database: %d %s\n", stat, msg ? msg : "");
      exit (1);
diff --git a/test/T568-lib-thread.sh b/test/T568-lib-thread.sh
index b45836cd..b4c24ca2 100755
--- a/test/T568-lib-thread.sh
+++ b/test/T568-lib-thread.sh
@@ -36,7 +36,9 @@ int main (int argc, char** argv)
    notmuch_query_t *query = NULL;
    const char *id = "${THREAD}";
 
-   stat = notmuch_database_open_verbose (argv[1], NOTMUCH_DATABASE_MODE_READ_WRITE, &db, &msg);
+   stat = notmuch_database_open_with_config (argv[1],
+					     NOTMUCH_DATABASE_MODE_READ_WRITE,
+					     NULL, NULL, &db, &msg);
    if (stat != NOTMUCH_STATUS_SUCCESS) {
      fprintf (stderr, "error opening database: %d %s\n", stat, msg ? msg : "");
      exit (1);
-- 
2.35.2

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

end of thread, other threads:[~2022-05-29 10:48 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-21 18:06 [PATCH 1/3] test: replace deprecated use of notmuch_database_open_verbose David Bremner
2022-05-21 18:06 ` [PATCH 2/3] test: replace deprecated use of notmuch_database_open David Bremner
2022-05-21 18:06 ` [PATCH 3/3] test: replace deprecated use of notmuch_database_create David Bremner
2022-05-29 10:48 ` [PATCH 1/3] test: replace deprecated use of notmuch_database_open_verbose 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).