def create(self, testcase): '''创建TestResult对象 :param testcase: 测试用例 :type testcase: TestCase :return TestResult ''' return testresult.XmlResult(testcase)
def create(self, testcase): '''创建TestResult对象 :param testcase: 测试用例 :type testcase: TestCase :return TestResult ''' filename = '%s.xml' % testcase.test_name.translate(self.TRANS) return testresult.XmlResult(filename)
def create(self, testcase): '''创建TestResult对象 :param testcase: 测试用例 :type testcase: TestCase :return TestResult ''' time_str = datetime.now().strftime("%Y%m%d_%H%M%S_%f")[:-3] filename = '%s_%s.xml' % (testcase.test_name.translate( self.TRANS), time_str) return testresult.XmlResult(filename)