[PowerPC] Collect some CallLowering arguments into a struct. [NFC]
[llvm-project.git] / lldb / packages / Python / lldbsuite / test_event / build_exception.py
blob3347d9fd7cf7ee5f3c178a7a218cad04bcc52792
1 class BuildError(Exception):
3 def __init__(self, called_process_error):
4 super(BuildError, self).__init__("Error when building test subject")
5 self.command = called_process_error.lldb_extensions.get(
6 "command", "<command unavailable>")
7 self.build_error = called_process_error.lldb_extensions.get(
8 "stderr_content", "<error output unavailable>")
10 def __str__(self):
11 return self.format_build_error(self.command, self.build_error)
13 @staticmethod
14 def format_build_error(command, command_output):
15 return "Error when building test subject.\n\nBuild Command:\n{}\n\nBuild Command Output:\n{}".format(
16 command, command_output.decode("utf-8"))