Issue 851: log archiving, reporting and results collection fix test names
| | |
| | | line.setAttribute("level", "%s" % level) |
| | | line.setAttribute("message", "%s" % message) |
| | | if level == 'Start': |
| | | tag=message.split(":")[3].strip() |
| | | tag=get_test_name(message.replace('testcase: ','')) |
| | | line.setAttribute("tag", "%s" % tag.lower()) |
| | | log.appendChild(line) |
| | | </script> |
| | |
| | | "exception_thrown", |
| | | "directory_server", |
| | | "test_env", |
| | | "staf_service" ] |
| | | "staf_service", |
| | | "get_test_name" ] |
| | | |
| | | class format_testcase: |
| | | 'Format the Test name objects' |
| | |
| | | def get_reljavadir(self): |
| | | return self.directory |
| | | |
| | | def get_test_name(name): |
| | | i=2 |
| | | __name='' |
| | | __tn=name.split(':') |
| | | while i < len(__tn): |
| | | __name += '%s:' % __tn[i] |
| | | i=i+1 |
| | | return __name[0:-1].strip() |
| | | |
| | | |
| | | |
| | |
| | | tcsuiteshort=tcsuite |
| | | else: |
| | | tcsuite=tcgroup |
| | | if tcnamesplit[2]: |
| | | tcshortname=tcnamesplit[2].strip() |
| | | else: |
| | | tcgroup=tcname |
| | | tcsuite=tcname |
| | | tcshortname=tcname |
| | | tcsuiteshort=tcname |
| | | |
| | | if testDict[tcname].has_key('pass'): |
| | |
| | | else: |
| | | tcresult='fail' |
| | | |
| | | tcshortname=get_test_name(tcname) |
| | | tcdurationsecs=test_time().timeToSeconds(tcduration) |
| | | |
| | | # Create the testgroup element |