summaryrefslogtreecommitdiffhomepage
path: root/tests/util.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/util.py')
-rw-r--r--tests/util.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/util.py b/tests/util.py
index db1f077c..051a36ba 100644
--- a/tests/util.py
+++ b/tests/util.py
@@ -20,4 +20,5 @@ def needs_builtin(name):
"""
Skip decorated test if builtin name does not exist.
"""
- return pytest.mark.skipif(not hasattr(builtins, name))
+ reason = "Test requires a builtin '{}'".format(name)
+ return pytest.mark.skipif(not hasattr(builtins, name), reason=reason)