Exemplo n.º 1
0
        public void Should_add_multiple_responsenegotiators()
        {
            //Given
            var configurator = new CarterConfigurator();

            //When
            configurator.WithResponseNegotiators(typeof(TestResponseNegotiator), typeof(TestXmlResponseNegotiator));

            //Then
            Assert.Equal(2, configurator.ResponseNegotiatorTypes.Count);
        }
Exemplo n.º 2
0
        public void Should_return_same_instance_when_adding_multiple_responsenegotiators()
        {
            //Given
            var configurator = new CarterConfigurator();

            //When
            var sameconfigurator = configurator.WithResponseNegotiators(typeof(TestResponseNegotiator), typeof(TestXmlResponseNegotiator));

            //Then
            Assert.Same(configurator, sameconfigurator);
        }
Exemplo n.º 3
0
        public void Should_exclude_negotiators()
        {
            //Given
            var configurator = new CarterConfigurator();

            //When
            var sameconfigurator = configurator.WithResponseNegotiators();

            //Then
            Assert.Equal(0, sameconfigurator.ResponseNegotiatorTypes.Count);
        }