[Python-checkins] cpython (2.7): use skipUnless

benjamin.peterson python-checkins at python.org
Wed Nov 26 21:37:36 CET 2014


https://hg.python.org/cpython/rev/3f5ac9f43027
changeset: 93606:3f5ac9f43027
branch: 2.7
parent: 93600:ac2175c5b743
user: Benjamin Peterson <benjamin at python.org>
date: Wed Nov 26 14:35:56 2014 -0600
summary:
 use skipUnless
files:
 Lib/test/test_readline.py | 6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Lib/test/test_readline.py b/Lib/test/test_readline.py
--- a/Lib/test/test_readline.py
+++ b/Lib/test/test_readline.py
@@ -15,9 +15,9 @@
 That's why the tests cover only a small subset of the interface.
 """
 
- @unittest.skipIf(not hasattr(readline, 'clear_history'),
- "The history update test cannot be run because the "
- "clear_history method is not available.")
+ @unittest.skipUnless(hasattr(readline, "clear_history"),
+ "The history update test cannot be run because the "
+ "clear_history method is not available.")
 def testHistoryUpdates(self):
 readline.clear_history()
 
-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /