2006-10-25 Joel E. Denny and Stepan Kasal Handle special characters in test case titles correctly. * lib/autotest/general.m4 (AT_INIT): Make sure at_help_all is AS_ESCAPE'd properly. (AT_SETUP): m4 quote and AS_ESCAPE the title properly everywhere. * tests/autotest.at (Backquote in a test title, Single-quote in a test title, Double-quote in a test title): Don't expect failure anymore. (Brackets in a test title, Pound in a test title): New tests. Index: lib/autotest/general.m4 =================================================================== RCS file: /cvsroot/autoconf/autoconf/lib/autotest/general.m4,v retrieving revision 1.215 diff -u -r1.215 general.m4 --- lib/autotest/general.m4 15 Oct 2006 01:12:02 -0000 1.215 +++ lib/autotest/general.m4 25 Oct 2006 13:31:25 -0000 @@ -279,7 +279,7 @@ # numerical order. at_format='m4_bpatsubst(m4_defn([AT_ordinal]), [.], [?])' # Description of all the test groups. -at_help_all='AT_help_all'])])dnl +at_help_all="AS_ESCAPE(AT_help_all)"])])dnl m4_divert_push([PARSE_ARGS])dnl at_prev= @@ -1170,15 +1170,15 @@ m4_ifdef([AT_capture_files], [m4_undefine([AT_capture_files])]) m4_define([AT_line], AT_LINE) m4_define([AT_xfail], [at_xfail=no]) -m4_define([AT_description], [$1]) +m4_define([AT_description], [[$1]]) m4_define([AT_ordinal], m4_incr(AT_ordinal)) m4_append([AT_groups_all], [ ]m4_defn([AT_ordinal])) m4_divert_push([TESTS])dnl AT_ordinal ) @%:@ AT_ordinal. m4_defn([AT_line]): $1 at_setup_line='m4_defn([AT_line])' - at_desc='$1' + at_desc="AS_ESCAPE([$1])" $at_quiet $ECHO_N "m4_format([%3d: %-]m4_eval(47 - m4_qdelta([$1]))[s], - AT_ordinal, [[$1]])[]$ECHO_C" + AT_ordinal, AS_ESCAPE([[$1]]))[]$ECHO_C" m4_divert_push([TEST_SCRIPT])dnl ]) @@ -1220,7 +1220,8 @@ # Complete a group of related tests. m4_define([AT_CLEANUP], [m4_append([AT_help_all], -m4_defn([AT_ordinal]);m4_defn([AT_line]);m4_defn([AT_description]);m4_ifdef([AT_keywords], [m4_defn([AT_keywords])]); +m4_defn([AT_ordinal]);m4_defn([AT_line]);m4_defn([AT_description]);dnl +m4_ifdef([AT_keywords], [m4_dquote(m4_defn([AT_keywords]))]); )dnl m4_divert_pop([TEST_SCRIPT])dnl Back to TESTS AT_xfail Index: tests/autotest.at =================================================================== RCS file: /cvsroot/autoconf/autoconf/tests/autotest.at,v retrieving revision 1.17 diff -u -r1.17 autotest.at --- tests/autotest.at 24 May 2006 03:46:00 -0000 1.17 +++ tests/autotest.at 25 Oct 2006 13:31:25 -0000 @@ -253,10 +253,12 @@ m4_define([AT_CHECK_AT_TITLE_CHAR], [AT_CHECK_AT_TITLE([$1 in a test title], [A $2 in my name], $3)]) -AT_CHECK_AT_TITLE_CHAR([Backquote], [`], [:]) -AT_CHECK_AT_TITLE_CHAR([Single-quote], ['], [:]) -AT_CHECK_AT_TITLE_CHAR([Double-quote], ["], [:]) +AT_CHECK_AT_TITLE_CHAR([Backquote], [`]) +AT_CHECK_AT_TITLE_CHAR([Single-quote], [']) +AT_CHECK_AT_TITLE_CHAR([Double-quote], ["]) AT_CHECK_AT_TITLE_CHAR([Backslash], [\]) +AT_CHECK_AT_TITLE_CHAR([Brackets], [[]]) +AT_CHECK_AT_TITLE_CHAR([Pound], [#]) ## ----------------- ##