Improve test reliability

This commit is contained in:
Jeremy Lakeman 2013-07-26 14:40:06 +09:30
parent 7634e1fcfb
commit fa012347a8

View File

@ -106,6 +106,13 @@ has_unread_messages() {
fi
}
messages_delivered() {
executeOk_servald meshms list messages $1 $2
if ! grep ":delivered:" $_tfw_tmp/stdout; then
return 1
fi
}
test_MessageThreading() {
set_instance +B
wait_until has_unread_messages $SIDB
@ -119,6 +126,7 @@ test_MessageThreading() {
set_instance +A
wait_until has_unread_messages $SIDA
wait_until messages_delivered $SIDA $SIDB
executeOk_servald meshms list messages $SIDA $SIDB
tfw_cat --stdout
assertStdoutGrep --stdout --matches=1 "^0:54:$SIDB:unread:Never mind\$"