Merge remote-tracking branch 'origin/master' into mm

This commit is contained in:
Anthony Sottile
2019-05-30 20:23:38 -07:00
7 changed files with 104 additions and 7 deletions

View File

@@ -719,7 +719,8 @@ class Class(PyCollector):
self.warn(
PytestCollectionWarning(
"cannot collect test class %r because it has a "
"__init__ constructor" % self.obj.__name__
"__init__ constructor (from: %s)"
% (self.obj.__name__, self.parent.nodeid)
)
)
return []
@@ -727,7 +728,8 @@ class Class(PyCollector):
self.warn(
PytestCollectionWarning(
"cannot collect test class %r because it has a "
"__new__ constructor" % self.obj.__name__
"__new__ constructor (from: %s)"
% (self.obj.__name__, self.parent.nodeid)
)
)
return []