

def end_test(self, name, attrs):
    'do sth when testing end'
    tags = attrs['tags']
    self.caserun['caseid'] = re.findall('ID_\\d+|id_\\d+', str(tags))[0][3:]
    self.caserun['status'] = (attrs['status'] + 'ED')
    self.caserun['end_time'] = attrs['endtime']
    self.caserun['message'] = attrs['message']
    if ('logtime' in self.caserun):
        self.caserun['log'] = ((((((((('\n' + ('*' * 30)) + '\n') + self.caserun['logtime']) + '\n') + attrs['message']) + '\n') + self.caserun['loginfo']) + '\n') + ('*' * 30))
    else:
        self.caserun['log'] = ''
    print_output(startend='end', passfail=self.caserun['status'], starttime=self.caserun['start_time'], endtime=self.caserun['end_time'], msg=self.caserun['casename'], others=self.caserun['message'])
    self.results_sender.send_pyobj(self.caserun)

dataset/ETHPy150Open idumpling/robotx/robotx/core/distlistener.py MultiListener.end_test/original