Show name argment in compatproperty deprecation message

This commit is contained in:
nmundar 2016-11-26 21:37:43 +01:00 committed by Bruno Oliveira
parent 0e6ad8e59f
commit 0a30f072e6
1 changed files with 1 additions and 1 deletions

View File

@ -191,7 +191,7 @@ class FSHookProxy:
def compatproperty(name):
def fget(self):
import warnings
warnings.warn("compatproperty is deprecated. Use pytest.name",
warnings.warn("This usage is deprecated, please use pytest.{0} instead".format(name),
PendingDeprecationWarning, stacklevel=2)
return getattr(pytest, name)