コード例 #1
0
        public void GivenBusInitializerOptionsWhenSetInvalidSerializerTypeShouldThrow()
        {
            var builder = new BusInitializerOptionsBuilder(new ConfigurationBuilder().Build());

            Action action = () => builder
                            .SetSerializer <AbstractSerializerStub>()
                            .Build();

            action.Should().Throw <ArgumentException>();
        }
コード例 #2
0
        public void GivenBusInitializerOptionsWhenNotSetConnectionStringShouldThrow()
        {
            var builder = new BusInitializerOptionsBuilder(new ConfigurationBuilder().Build());

            Action action = () => builder
                            .SetSerializer <BusSerializerStub>()
                            .Build();

            action.Should().Throw <ArgumentNullException>();
        }