Commit 344541af authored by Jason Madden's avatar Jason Madden

Use libuv as fallback from libev cffi

parent 24e8c7fd
......@@ -19,8 +19,10 @@ except ImportError:
if lib == 'libuv':
from gevent.libuv import loop as _core
else:
try:
from gevent.libev import corecffi as _core
except ImportError:
from gevent.libuv import loop as _core
copy_globals(_core, globals())
......
......@@ -17,7 +17,7 @@ class Test(greentest.TestCase):
error_fatal = False
def setUp(self):
self.server = server.StreamServer((greentest.DEFAULT_BIND_ADDR, 0), readall)
self.server = server.StreamServer(('127.0.0.1', 0), readall)
self.server.start()
def tearDown(self):
......@@ -25,7 +25,7 @@ class Test(greentest.TestCase):
def test_recv_closed(self):
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect((greentest.DEFAULT_LOCAL_HOST_ADDR, self.server.server_port))
sock.connect(('localhost', self.server.server_port))
receiver = gevent.spawn(sock.recv, 25)
try:
gevent.sleep(0.001)
......@@ -40,7 +40,7 @@ class Test(greentest.TestCase):
def test_recv_twice(self):
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect((greentest.DEFAULT_LOCAL_HOST_ADDR, self.server.server_port))
sock.connect(('localhost', self.server.server_port))
receiver = gevent.spawn(sock.recv, 25)
try:
gevent.sleep(0.001)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment