Author: Brian Kearns <[email protected]>
Branch:
Changeset: r62616:95f16920996f
Date: 2013-03-21 17:02 -0400
http://bitbucket.org/pypy/pypy/changeset/95f16920996f/
Log: remove this random/unexplained loosening of test, it represents
bogus behavior
diff --git a/pypy/module/_socket/test/test_sock_app.py
b/pypy/module/_socket/test/test_sock_app.py
--- a/pypy/module/_socket/test/test_sock_app.py
+++ b/pypy/module/_socket/test/test_sock_app.py
@@ -35,18 +35,14 @@
def test_gethostbyaddr():
host = "localhost"
expected = socket.gethostbyaddr(host)
- # On some versions of MacOSX, we get two '0.0.0.0' entries in the
addresslist.
- expecteds = (expected, expected[:2] + (['0.0.0.0'], ), expected[:2] +
(['0.0.0.0']*2, ))
ip = space.appexec([w_socket, space.wrap(host)],
"(_socket, host): return _socket.gethostbyaddr(host)")
- assert space.unwrap(ip) in expecteds
+ assert space.unwrap(ip) == socket.gethostbyaddr(host)
+
host = "127.0.0.1"
- expected = socket.gethostbyaddr(host)
- # On some versions of MacOSX, we get two '0.0.0.0' entries in the
addresslist.
- expecteds = (expected, expected[:2] + (['0.0.0.0'], ), expected[:2] +
(['0.0.0.0']*2, ))
ip = space.appexec([w_socket, space.wrap(host)],
"(_socket, host): return _socket.gethostbyaddr(host)")
- assert space.unwrap(ip) in expecteds
+ assert space.unwrap(ip) == socket.gethostbyaddr(host)
def test_getservbyname():
name = "smtp"
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit