[lldb/test] Update lldbutil.fetch_next_event to match broadcaster class
This patch updates the lldbutil.fetch_next_event helper function to
either match a specific broadcaster or match a whole broadcaster class.
This is very handy when testing process events for interactive scripted
process debugging.
This also fixes a bug in the failing case, where SBEvent.GetDescription
expects a SBStream argument. We never took that code path in the
original implementation so we didn't hit that bug.
Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
Maybe update the docstring to reflect this new parameter? Something like If match_class is true, the provided broadcaster will be matched by class rather than instance?