[RFA 2/2] Make some test names invariant

Pedro Alves palves@redhat.com
Thu Sep 15 15:16:00 GMT 2016


On 09/14/2016 11:59 PM, Tom Tromey wrote:
> While working on the previous patch, I noticed that the test names in
> process-dies-while-detaching include the PID of some test process,
> making it so that the test names change between runs.  This patch
> fixes the problem.

LGTM.

However, FYI, with the current "definition" of test names, it 
doesn't actually change, because tools should be ignoring the
trailing " (...)" bit.  See:

 https://sourceware.org/gdb/wiki/GDBTestcaseCookbook#Do_not_use_.22tail_parentheses.22_on_test_messages

We've always had to consider this, given "$test (timeout)", etc.

Note that the wiki doesn't say it, and I don't think we've ever
discussed it, but but the space before the open parens should matter
when deciding whether to ignore the trailing bit.  If there's no space,
it shouldn't be ignored.  This in order to make it possible to write
tests that call functions without coming up with odd contortions,
like, e.g., "print foo(1)".

Thanks,
Pedro Alves



More information about the Gdb-patches mailing list