Beispiel #1
0
        public void AddExecutionLogging_adds_service_host_configuration(WcfServiceHostConfiguration <TestService> configurator, Action <ServiceMetadataBehavior> serviceMetadataBehaviorConfigurator)
        {
            Assume.That(configurator.ServiceHostConfigurations, Is.Empty);

            ServiceHostConfiguratorExtensions.AddExecutionLogging(configurator);

            Assert.That(configurator.ServiceHostConfigurations, Has.One.InstanceOf <Action <ServiceHost> >());
        }
Beispiel #2
0
        public void AddExecutionLogging_adds_behavior_to_host(WcfServiceHostConfiguration <TestService> configurator, ServiceHost host)
        {
            ServiceHostConfiguratorExtensions.AddExecutionLogging(configurator);

            var configuration = configurator.ServiceHostConfigurations.First();

            configuration(host);

            Assert.That(host.Description.Behaviors.Find <ExecutionLoggingBehavior>(), Is.Not.Null);
        }