aboutsummaryrefslogtreecommitdiff
path: root/test/T530-upgrade.sh
diff options
context:
space:
mode:
authorJani Nikula <jani@nikula.org>2017-02-26 15:43:00 +0200
committerDavid Bremner <david@tethera.net>2017-03-09 09:01:21 -0400
commitd0cd253b37646d9364d046e1d3edb022a58c105a (patch)
treeff9af83a8bd1e3380e81c3e3d73389fc98d190a7 /test/T530-upgrade.sh
parentb8f12bd3717aa446ef04197734af7a055e6909fe (diff)
test: require test_begin_subtest before test_expect_success
Unify the subtests by requiring test_begin_subtest before test_expect_success. (Similar change for test_expect_code will follow.) This increases clarity in the test scripts by having a separate line for the start of the subtest with the heading, and makes it possible to simplify the test infrastructure by making all subtests similar.
Diffstat (limited to 'test/T530-upgrade.sh')
-rwxr-xr-xtest/T530-upgrade.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/T530-upgrade.sh b/test/T530-upgrade.sh
index a3a7d39c..f0fd1511 100755
--- a/test/T530-upgrade.sh
+++ b/test/T530-upgrade.sh
@@ -10,8 +10,8 @@ if [ ! -e ${TEST_DIRECTORY}/test-databases/${dbtarball} ]; then
test_subtest_missing_external_prereq_["${dbtarball} - fetch with 'make download-test-databases'"]=t
fi
+test_begin_subtest "database checksum"
test_expect_success \
- 'database checksum' \
'( cd $TEST_DIRECTORY/test-databases &&
sha256sum --quiet --check --status ${dbtarball}.sha256 )'
@@ -25,7 +25,8 @@ test_begin_subtest "path: search does not work with old database version"
output=$(notmuch search path:foo)
test_expect_equal "$output" ""
-test_expect_success 'pre upgrade dump' 'notmuch dump | sort > pre-upgrade-dump'
+test_begin_subtest "pre upgrade dump"
+test_expect_success 'notmuch dump | sort > pre-upgrade-dump'
test_begin_subtest "database upgrade from format version 1"
output=$(notmuch new | sed -e 's/^Backing up tags to .*$/Backing up tags to FILENAME/')