diff --git a/uvloop/_testbase.py b/uvloop/_testbase.py index a645645..4d6f187 100644 --- a/uvloop/_testbase.py +++ b/uvloop/_testbase.py @@ -306,7 +306,11 @@ class AIOTestCase(BaseTestCase): super().tearDown() def new_loop(self): - return asyncio.new_event_loop() + if hasattr(asyncio, 'ProactorEventLoop'): + # On Windows try to use IOCP event loop. + return asyncio.ProactorEventLoop() + else: + return asyncio.new_event_loop() def has_IPv6():