public void WithInternal_should_return_expected_result()
        {
            var subject = new ConnectionPoolSettings();

            var result = subject.WithInternal(isPausable: false);

            result.IsPausable.Should().Be(false);
            result = subject.WithInternal(isPausable: true);
            result.IsPausable.Should().Be(true);
        }
        private IConnectionPoolFactory CreateConnectionPoolFactory()
        {
            var streamFactory = CreateTcpStreamFactory(_tcpStreamSettings);

            var connectionFactory = new BinaryConnectionFactory(
                _connectionSettings,
                streamFactory,
                _eventAggregator,
                _clusterSettings.ServerApi);

            var connectionPoolSettings = _connectionPoolSettings.WithInternal(isPausable: !_connectionSettings.LoadBalanced);

            return(new ExclusiveConnectionPoolFactory(
                       connectionPoolSettings,
                       connectionFactory,
                       _eventAggregator));
        }