[PATCH 1/4] test: mark some tests as broken when run as root.

2023-01-04 Thread David Bremner
File permission errors e.g., are hard to trigger as root. --- test/T050-new.sh | 1 + test/T150-tagging.sh | 1 + test/test-lib.sh | 6 ++ 3 files changed, 8 insertions(+) diff --git a/test/T050-new.sh b/test/T050-new.sh index cb67889c..240c1810 100755 --- a/test/T050-new.sh +++

[PATCH 4/4] debian: add autopkgtests

2023-01-04 Thread David Bremner
We generate output to stderr for BROKEN tests, which are not failures, so tell the test runner not to fail because of output on stderr. --- debian/tests/control | 13 + test/T800-asan.sh| 8 ++-- test/defaults.sh | 2 +- 3 files changed, 20 insertions(+), 3 deletions(-)

[PATCH 3/4] test: support testing notmuch as installed

2023-01-04 Thread David Bremner
We put some effort into testing the built copy rather than some installed copy. On the other hand for people like packagers, testing the installed copy is also of interest. When NOTMUCH_TEST_INSTALLED is set to a nonempty value, tests do not require a built notmuch tree or running configure.

[PATCH 2/4] test: check for empty/missing files in test_expect_equal_message_body

2023-01-04 Thread David Bremner
Messages can have empty bodies, but empty files are not messages. --- test/test-lib.sh | 8 1 file changed, 8 insertions(+) diff --git a/test/test-lib.sh b/test/test-lib.sh index c2b8cd8d..a647790a 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -388,6 +388,14 @@

Support testing notmuch as installed

2023-01-04 Thread David Bremner
This is mainly the same as id:20211025145753.3031094-1-da...@tethera.net, with some adjustments for changes in notmuch in the last year. The main place it could be improved is having less tests disabled in installed mode. That seems like something that someone(TM) could do incrementally. There