def test_fromFuture(self):
        """
        L{defer.Deferred.fromFuture} returns a L{defer.Deferred} that fires
        when the given L{asyncio.Future} does.
        """
        loop = new_event_loop()
        aFuture = Future(loop=loop)
        d = defer.Deferred.fromFuture(aFuture)
        self.assertNoResult(d)
        aFuture.set_result(7)
        callAllSoonCalls(loop)
        self.assertEqual(self.successResultOf(d), 7)

        L{defer.Deferred.fromFuture} returns a L{defer.Deferred} that fires
        when the given L{asyncio.Future} does.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/test/test_defer.py