<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def do_failures(self, arg):
 """Prints a list of test cases that failed for the current unit test and analysis group settings. To only check failure on specific output files, set the list of files to check as arguments. """

        usable, filename, append = self._redirect_split(arg)
        a = self.tests[self.active]
        args = self.curargs
        splitargs = usable.split()
        if len(splitargs) > 0:
            tfilter = splitargs[0]
        else:
            tfilter = "*"

        outfiles = None
        if len(splitargs) > 1:
            outfiles = splitargs[1:len(splitargs)]

        result = a.failures(outfiles, args["threshold"], tfilter)
        self._redirect_output(result, filename, append, msg.info)