Author: Christian Tismer <[email protected]>
Branch: win64-stage1
Changeset: r50047:234142ad1aa7
Date: 2011-12-01 23:05 +0100
http://bitbucket.org/pypy/pypy/changeset/234142ad1aa7/
Log: fixed smallintobject tests. The type() checks make no longer sense
diff --git a/pypy/objspace/std/test/test_smallintobject.py
b/pypy/objspace/std/test/test_smallintobject.py
--- a/pypy/objspace/std/test/test_smallintobject.py
+++ b/pypy/objspace/std/test/test_smallintobject.py
@@ -64,7 +64,7 @@
f1 = wrapint(self.space, x)
f2 = wrapint(self.space, y)
result = self.space.unwrap(self.space.add(f1, f2))
- assert result == x+y and type(result) == type(x+y)
+ assert result == x+y and
def test_sub(self):
for x in [1, 100, sys.maxint // 2 - 50,
@@ -74,15 +74,16 @@
f1 = wrapint(self.space, x)
f2 = wrapint(self.space, y)
result = self.space.unwrap(self.space.sub(f1, f2))
- assert result == x-y and type(result) == type(x-y)
-
+ assert result == x-y
+
def test_mul(self):
for x in [0, 1, 100, sys.maxint // 2 - 50, sys.maxint - 1000]:
for y in [0, 1, 100, sys.maxint // 2 - 50, sys.maxint - 1000]:
f1 = wrapint(self.space, x)
f2 = wrapint(self.space, y)
result = self.space.unwrap(self.space.mul(f1, f2))
- assert result == x*y and type(result) == type(x*y)
+ assert result == x*y
+
def test_div(self):
for i in range(10):
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit