now i am learning a python test framework ----nose
and i found that when something went wrong, such as "assert 8==9"
the output is ugly like below:
Code:
Traceback (most recent call last):
File "/usr/local/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/Users/wdy/Documents/noselearn/test.py", line 5, in test3
assert a == 9
AssertionError:
8 = 8
while what i really want to get is something like this:
Code:
in /Users/wdy/Documents/noselearn/test.py, [method] test3 Failed
and the reason is that line 5, assert 8==9
I googled and get some idea as following:
use nose's API and implement a plugin ,but i am a newbie to nose and its plugin, is there anyone who can give some detailed advice?