public void UpdateConfiguration_WithNullHystrixRabbitMQServiceInfo_ReturnsInitialConfiguration()
        {
            var configurer = new HystrixProviderConfigurer();
            var config     = new HystrixProviderConnectorOptions()
            {
                Server      = "localhost",
                Port        = 1234,
                Username    = "******",
                Password    = "******",
                VirtualHost = "vhost"
            };

            configurer.UpdateConfiguration(null, config);

            Assert.Equal("localhost", config.Server);
            Assert.Equal(1234, config.Port);
            Assert.Equal("username", config.Username);
            Assert.Equal("password", config.Password);
            Assert.Equal("vhost", config.VirtualHost);
            Assert.Null(config.Uri);
        }
        public void UpdateConfiguration_WithHystrixRabbitMQSSLServiceInfo_UpdatesConfigurationFromServiceInfo()
        {
            var configurer = new HystrixProviderConfigurer();
            var config     = new HystrixProviderConnectorOptions()
            {
                Server      = "localhost",
                Port        = 1234,
                Username    = "******",
                Password    = "******",
                VirtualHost = "vhost"
            };
            var si = new HystrixRabbitMQServiceInfo("MyId", "amqps://*****:*****@example.com:5671/si_vhost", false);

            configurer.UpdateConfiguration(si, config);

            Assert.True(config.SslEnabled);
            Assert.Equal("example.com", config.Server);
            Assert.Equal(5671, config.SslPort);
            Assert.Equal("si_username", config.Username);
            Assert.Equal("si_password", config.Password);
            Assert.Equal("si_vhost", config.VirtualHost);
        }