]> git.notmuchmail.org Git - notmuch/blobdiff - test/test-lib-common.sh
tests/smime: include secret key material for Bob
[notmuch] / test / test-lib-common.sh
index 4300eb65418f1afa8d4cd93c3fd1d1a001b47ccf..2f7950ac75b7b6c61777560bb933d847b9a7e3f7 100644 (file)
@@ -31,20 +31,16 @@ fi
 
 backup_database () {
     test_name=$(basename $0 .sh)
-    rm -rf $NOTMUCH_BUILDDIR/test/notmuch-dir-backup."$test_name"
-    cp -pR ${MAIL_DIR}/.notmuch $NOTMUCH_BUILDDIR/test/notmuch-dir-backup."${test_name}"
+    rm -rf $TMP_DIRECTORY/notmuch-dir-backup."$test_name"
+    cp -pR ${MAIL_DIR}/.notmuch $TMP_DIRECTORY/notmuch-dir-backup."${test_name}"
 }
 
 restore_database () {
     test_name=$(basename $0 .sh)
     rm -rf ${MAIL_DIR}/.notmuch
-    cp -pR $NOTMUCH_BUILDDIR/test/notmuch-dir-backup."${test_name}" ${MAIL_DIR}/.notmuch
+    cp -pR $TMP_DIRECTORY/notmuch-dir-backup."${test_name}" ${MAIL_DIR}/.notmuch
 }
 
-# Test the binaries we have just built.  The tests are kept in
-# test/ subdirectory and are run in 'trash directory' subdirectory.
-TEST_DIRECTORY=$NOTMUCH_BUILDDIR/test
-
 # Prepend $TEST_DIRECTORY/../lib to LD_LIBRARY_PATH, to make tests work
 # on systems where ../notmuch depends on LD_LIBRARY_PATH.
 LD_LIBRARY_PATH=${TEST_DIRECTORY%/*}/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}