目前,如果测试有docstring,它将被打印在测试控制台(TestCase.ShortDescrption())上,如果它是测试的None名称(TestCase.id()),那么我想将TestCase.id()添加到TestCase.ShortDescription()中,这样不管docstring是否存在,TestCase.id()都会被打印出来。样本测试: def test_bar_1(self):
""" this is
我使用描述符来定义接口类的寄存器: def __init__(self, address, docstring="instance docstring#should show the docstring "the first register"i = Interface()
i.r( #should show the docstring "thefirst register" when parentheses