Both matching the debuginfo to some known output and running gdb/lldb with certain commands and testing the output.