]> git.notmuchmail.org Git - notmuch/commitdiff
test: add test for creating database in various configurations.
authorDavid Bremner <david@tethera.net>
Tue, 26 Jul 2022 00:37:41 +0000 (20:37 -0400)
committerDavid Bremner <david@tethera.net>
Sat, 3 Sep 2022 11:24:43 +0000 (08:24 -0300)
The existing database creation (via add_email_corpus) was always done
in the traditional configuration. The use of xapian-metadata is just
to portably ensure that there is a database created where we expect
there to be.

test/T055-path-config.sh

index 58c824a299bdf0e00be9b0092795440e8a03a642..45545d885182afd9095ff8925a20203057d48c03 100755 (executable)
@@ -313,6 +313,12 @@ user.other_email
 user.primary_email
 EOF
    test_expect_equal_file EXPECTED OUTPUT
+
+   test_begin_subtest "create database ($config)"
+   rm -r ${XAPIAN_PATH}
+   notmuch new
+   test_expect_equal "$(xapian-metadata get ${XAPIAN_PATH} version)" 3
+
    case $config in
        XDG*)
           test_begin_subtest "Set shadowed config value in database ($config)"