2 ######################################################
4 # Test that an '%<(function)...' if-construct correctly
5 # tests whether 'str' is empty if the function returns
6 # a string, and tests 'value' if the function returns
9 ######################################################
11 if [ -z "${MH_TEST_COMMON}" ]; then
12 echo "MH_TEST_COMMON not set; try running via 'make check'"
19 # create test replgroupcomps
20 form=$MH_TEST_DIR/$$.replgroupcomps
22 X-STRING: %(num)%(lit)%<(lit FOO) found%| missing%>\n\
23 X-NUMBER: %(num)%(lit)%<(num 3) yes%| no%>\n\
24 X-NOSTRING: %(num 3)%(lit x)%<(lit) found%| missing%>\n\
25 X-NONUMBER: %(num 3)%(lit x)%<(num) yes%| no%>\n\
29 expected=$MH_TEST_DIR/$$.expected
30 actual=$MH_TEST_DIR/Mail/draft
35 X-NOSTRING: 3x missing
39 > This is message number 1
42 repl -editor true -format -form $form -group -nocc me -nowhatnowproc 1 || exit 1
44 diff -u $expected $actual