'L{defer.Deferred.asFuture} returns a L{asyncio.Future} which fires when
the given L{defer.Deferred} does.'

def test_asFuture(self):

    d = defer.Deferred()
    loop = new_event_loop()
    aFuture = d.asFuture(loop)
    self.assertEqual(aFuture.done(), False)
    d.callback(13)
    callAllSoonCalls(loop)
    self.assertEqual(self.successResultOf(d), None)
    self.assertEqual(aFuture.result(), 13)
