public void SecondConnectionEstablishedIfFirstInUse() { var cf = new ConnectionPoolingConnectionFactory(rootConnectionFactory); var conn1 = cf.Get(); var conn2 = cf.Get(); AssertRealConnection1(conn1); AssertRealConnection2(conn2); conn1.Dispose(); conn2.Dispose(); }
public void RetrieveSameConnectionOverAndOver() { var cf = new ConnectionPoolingConnectionFactory(rootConnectionFactory); var conn1 = cf.Get(); AssertRealConnection1(conn1); conn1.Dispose(); conn1 = cf.Get(); AssertRealConnection1(conn1); conn1.Dispose(); conn1 = cf.Get(); AssertRealConnection1(conn1); conn1.Dispose(); conn1 = cf.Get(); AssertRealConnection1(conn1); conn1.Dispose(); }