[Checkins] SVN: zope.proxy/branches/regebro-python3/src/zope/proxy/ Fixed some easy things.
Lennart Regebro
regebro at gmail.com
Fri Nov 19 17:21:51 EST 2010
Log message for revision 118507:
Fixed some easy things.
Changed:
U zope.proxy/branches/regebro-python3/src/zope/proxy/_zope_proxy_proxy.c
U zope.proxy/branches/regebro-python3/src/zope/proxy/tests/test_proxy.py
-=-
Modified: zope.proxy/branches/regebro-python3/src/zope/proxy/_zope_proxy_proxy.c
===================================================================
--- zope.proxy/branches/regebro-python3/src/zope/proxy/_zope_proxy_proxy.c 2010-11-19 22:17:40 UTC (rev 118506)
+++ zope.proxy/branches/regebro-python3/src/zope/proxy/_zope_proxy_proxy.c 2010-11-19 22:21:51 UTC (rev 118507)
@@ -231,7 +231,6 @@
#else
name_as_string = PyBytes_AS_STRING(PyUnicode_AsUTF8String(name));
#endif
- printf("======\n%s=======\n", name_as_string);
wrapped = Proxy_GET_OBJECT(self);
if (wrapped == NULL) {
Modified: zope.proxy/branches/regebro-python3/src/zope/proxy/tests/test_proxy.py
===================================================================
--- zope.proxy/branches/regebro-python3/src/zope/proxy/tests/test_proxy.py 2010-11-19 22:17:40 UTC (rev 118506)
+++ zope.proxy/branches/regebro-python3/src/zope/proxy/tests/test_proxy.py 2010-11-19 22:21:51 UTC (rev 118507)
@@ -239,7 +239,10 @@
def test_odd_unops(self):
# unops that don't return a proxy
P = self.new_proxy
- for func in hex, oct, lambda x: not x:
+ funcs = (lambda x: not x,)
+ if sys.version < '3':
+ func += (oct, hex)
+ for func in funcs:
self.assertEqual(func(P(100)), func(100))
binops = [
@@ -279,6 +282,9 @@
self.assertEqual(pa, 4)
def test_coerce(self):
+ if sys.version > '3':
+ # No coercion in Python 3
+ return
P = self.new_proxy
# Before 2.3, coerce() of two proxies returns them unchanged
More information about the checkins
mailing list