public void Dispose_does_not_dispose_of_encapsulated_socket() {
     var mock = new MockSocket();
     ISocket reclaimed = null;
     var socket = new PoolSocket(mock, (s) => reclaimed = s);
     socket.Dispose();
     Assert.AreEqual(0, mock.DisposeCalled);
 }
 public void Dispose_calls_reclaim_callback_with_encapsulated_socket() {
     var mock = new MockSocket();
     ISocket reclaimed = null;
     var socket = new PoolSocket(mock, (s) => reclaimed = s);
     socket.Dispose();
     Assert.AreSame(mock, reclaimed);
 }