test suite: Generate message filenames from count, not Message-Id.

We're about to add a test with an excessively long message-id, (512
characters or so). This exceeds filename length limits, so just always
the simple counter to generate the filenames, (which we were doing for
messages with non-custom IDs anyway).
This commit is contained in:
Carl Worth 2010-06-04 12:38:11 -07:00
parent 552c61e269
commit 77ab738343

View file

@ -85,12 +85,12 @@ generate_message ()
local -A template="($@)"
local additional_headers
gen_msg_cnt=$((gen_msg_cnt + 1))
gen_msg_name=msg-$(printf "%03d" $gen_msg_cnt)
if [ -z "${template[id]}" ]; then
gen_msg_cnt=$((gen_msg_cnt + 1))
gen_msg_name=msg-$(printf "%03d" $gen_msg_cnt)
gen_msg_id="${gen_msg_name}@notmuch-test-suite"
else
gen_msg_name="msg-${template[id]}"
gen_msg_id="${template[id]}"
fi