bpo-14265: Adds fully qualified test name to unittest output (GH-32138)

Co-authored-by: Andrew Svetlov <andrew.svetlov@gmail.com>
This commit is contained in:
Sam Ezeh 2022-03-29 16:02:09 +01:00 committed by GitHub
parent 356997cccc
commit 755be9b150
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 63 additions and 49 deletions

View file

@ -478,7 +478,7 @@ class TestCase(object):
return hash((type(self), self._testMethodName))
def __str__(self):
return "%s (%s)" % (self._testMethodName, strclass(self.__class__))
return "%s (%s.%s)" % (self._testMethodName, strclass(self.__class__), self._testMethodName)
def __repr__(self):
return "<%s testMethod=%s>" % \