def METHOD_NAME(self):
    # to ease debugging we display the error logs in the test log
    origAddCompleteLog = BuildStep.addCompleteLog
    def addCompleteLog(self, name, _log):
        if name.endswith("err.text"):
            log.msg("got error log!", name, _log)
        return origAddCompleteLog(self, name, _log)
    self.patch(BuildStep, "addCompleteLog", addCompleteLog)
    if 'BBTRACE' in os.environ:
        enable_trace(self)