[pypy-svn] r11895 - pypy/dist/lib-python/modified-2.3.4/test
arigo at codespeak.net
arigo at codespeak.net
Tue May 3 21:56:14 CEST 2005
Author: arigo
Date: Tue May 3 21:56:14 2005
New Revision: 11895
Modified:
pypy/dist/lib-python/modified-2.3.4/test/test_class.py
Log:
Using "is not" to compare two strings? Bad idea.
Modified: pypy/dist/lib-python/modified-2.3.4/test/test_class.py
==============================================================================
--- pypy/dist/lib-python/modified-2.3.4/test/test_class.py (original)
+++ pypy/dist/lib-python/modified-2.3.4/test/test_class.py Tue May 3 21:56:14 2005
@@ -353,7 +353,7 @@
try:
A().a # Raised AttributeError: A instance has no attribute 'a'
except AttributeError, x:
- if str(x) is not "booh":
+ if str(x) != "booh":
print "attribute error for A().a got masked:", str(x)
class E:
More information about the Pypy-commit
mailing list