2 test_description="\"notmuch dump\" and \"notmuch restore\""
7 test_expect_success "Dumping all tags" "generate_message &&
9 notmuch dump dump.expected"
11 test_begin_subtest "Clearing all tags"
12 sed -e "s/(\([^(]*\))$/()/" < dump.expected > clear.expected
13 notmuch restore clear.expected
14 notmuch dump clear.actual
15 test_expect_equal "$(< clear.actual)" "$(< clear.expected)"
17 test_begin_subtest "Restoring original tags"
18 notmuch restore dump.expected
19 notmuch dump dump.actual
20 test_expect_equal "$(< dump.actual)" "$(< dump.expected)"
22 test_expect_success "Restore with nothing to do" "notmuch restore dump.expected"