|
基于原代码添加了这个:
报错信息:
Traceback (most recent call last):
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\unittest\suite.py", line 163, in _handleClassSetUp
setUpClass()
TypeError: setUpClass() takes 0 positional arguments but 1 was given
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\appium\workspace\new test\Simple-test.py", line 72, in <module>
runner.run(suite)
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\HTMLTestRunner.py", line 628, in run
test(result)
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\unittest\suite.py", line 84, in __call__
return self.run(*args, **kwds)
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\unittest\suite.py", line 114, in run
self._handleClassSetUp(test, result)
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\unittest\suite.py", line 170, in _handleClassSetUp
self._addClassOrModuleLevelException(result, e, errorName)
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\unittest\suite.py", line 216, in _addClassOrModuleLevelException
result.addError(error, sys.exc_info())
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\HTMLTestRunner.py", line 584, in addError
output = self.complete_output()
File "C:\Users\zhengtao\AppData\Local\Programs\Python\Python35\lib\HTMLTestRunner.py", line 558, in complete_output
return self.outputBuffer.getvalue()
AttributeError: '_TestResult' object has no attribute 'outputBuffer'
|
|