public void resolves_single_logger_as_just_that_instance() { var inner = new ConsoleBusLogger(); BusLogger.Combine(new IBusLogger[] { inner }) .ShouldBeSameAs(inner); }
public HandlerPipeline(IEnvelopeSender sender, IEnvelopeSerializer serializer, HandlerGraph graph, IReplyWatcher replies, IBusLogger[] loggers) { _sender = sender; _serializer = serializer; _graph = graph; _replies = replies; Logger = BusLogger.Combine(loggers); }
public void resolves_multiple_loggers_to_composite() { var inner1 = Substitute.For <IBusLogger>(); var inner2 = Substitute.For <IBusLogger>(); var inner3 = Substitute.For <IBusLogger>(); BusLogger.Combine(new IBusLogger[] { inner1, inner2, inner3 }) .ShouldBeOfType <CompositeLogger>() .Loggers.ShouldHaveTheSameElementsAs(inner1, inner2, inner3); }
public void resolves_no_loggers_as_nullo() { BusLogger.Combine(new IBusLogger[0]) .ShouldBeOfType <BusLogger>(); }
public EnvelopeSender(ChannelGraph channels, IEnvelopeSerializer serializer, IBusLogger[] loggers) { _channels = channels; _serializer = serializer; Logger = BusLogger.Combine(loggers); }