public void Databus_should_not_be_registered_if_no_databus_property_is_found()
        {
            Configure.With(new[] { typeof(MessageWithoutDataBusProperty) })
                .DefineEndpointName("xyz")
                .DefaultBuilder();

            IWantToRunBeforeConfigurationIsFinalized bootstrapper = new Bootstrapper();

            bootstrapper.Run();

            Assert.False(Configure.Instance.Configurer.HasComponent<IDataBus>());
        }
        public void Databus_should_be_registered_if_a_databus_property_is_found()
        {
            Configure.With(new[] {typeof (MessageWithDataBusProperty)})
                .DefineEndpointName("xyz")
                .DefaultBuilder();

            IWantToRunBeforeConfigurationIsFinalized bootstrapper = new Bootstrapper();

            Configure.Instance.Configurer.ConfigureComponent<InMemoryDataBus>(DependencyLifecycle.SingleInstance);

            bootstrapper.Run();

            Assert.True(Configure.Instance.Configurer.HasComponent<IDataBus>());
        }