labath added a comment.

In D76407#1931551 <https://reviews.llvm.org/D76407#1931551>, @jingham wrote:

> This test just seems wrong to me.  We can pretend that processes that haven't 
> crashed don't have crash_info, and manually suppress the output in lldb if 
> the stop state isn't a crash.  But it seems useful to ask "what are the 
> crash_info bits in flight right now" even if you haven't crashed.  So that 
> doesn't seem right to me.  Or you have to acknowledge that you have no way of 
> knowing whether there is crash info data hanging around, in which case any 
> test that depends on there being none is an invalid test.  I'd delete this 
> whole test, since it seems to me like it will only ever succeed by accident.


If it cannot reliably produce an process with no crash annotations, then the 
test is bad. But that doesn't mean we should not test the code path which we 
would take if the process happened to not have any crash annotations.

(This looks like a very good example of the limitations of the "run a process 
and see what happens" kinds of tests, and why I think we should avoid them 
whereever possible.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D76407/new/

https://reviews.llvm.org/D76407



_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to