diff options
author | Guilhem Moulin <guilhem@fripost.org> | 2024-04-05 20:40:58 +0200 |
---|---|---|
committer | Guilhem Moulin <guilhem@fripost.org> | 2024-04-05 20:45:35 +0200 |
commit | 8f11b2625b98831a591a73c8928d62c1df11aadb (patch) | |
tree | 207c27cf98bad84a81b3a8ba0775a75a42e32b51 | |
parent | a4accc44ac1fddffba31d9bf52b76738a3562057 (diff) |
-rw-r--r-- | tests/pullimap/t | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/pullimap/t b/tests/pullimap/t index 879c5d1..e508784 100644 --- a/tests/pullimap/t +++ b/tests/pullimap/t @@ -13,6 +13,17 @@ if ! st="$(stat -c"%#a" -- "$XDG_DATA_HOME/pullimap/remote")" || [ "$st" != "060 fi step_done +step_start "\`pullimap\` locks its statefile" +pullimap --idle "remote" & PID=$! +trap "ptree_abort $PID" EXIT INT TERM +# wait a short while so we have time to lock the database (ugly and racy...) +sleep .5 +! pullimap "remote" || error +grep -F "Can't lock $XDG_DATA_HOME/pullimap/remote: Resource temporarily unavailable at " <"$STDERR" || error +ptree_abort $PID +trap - EXIT INT TERM +step_done + # compare mailboxes (can't compare the RFC 3501 TEXT as the LMTPd inconditionally # adds a Return-Path: header -- and also Delivered-To: and Received: to by default) list_mails_sha256() { |