

def test_close(self):
    pool = Pool(url='ws://localhost:8182/', maxsize=2, username='stephen', password='password', future_class=Future)

    @trollius.coroutine
    def go():
        c1 = (yield From(pool.acquire()))
        c2 = (yield From(pool.acquire()))
        (yield From(pool.release(c2)))
        pool.close()
        self.assertTrue(c2.conn.closed)
        self.assertFalse(c1.conn.closed)
        c1.close()
    self.loop.run_until_complete(go())

dataset/ETHPy150Open davebshow/gremlinclient/tests/test_trollius.py TrolliusPoolTest.test_close/original