public async Task ShouldAllowMultipleStops()
        {
            var testee = new RunningEndpointInstance(
                new SettingsHolder(),
                new FakeBuilder(),
                new List<TransportReceiver>(),
                new FeatureRunner(new FeatureActivator(new SettingsHolder())),
                new MessageSession(new RootContext(null, null, null)), new FakeTransportInfrastructure());

            await testee.Stop();

            Assert.That(async () => await testee.Stop(), Throws.Nothing);
        }
示例#2
0
        public async Task ShouldAllowMultipleStops()
        {
            var testee = new RunningEndpointInstance(
                new SettingsHolder(),
                new FakeBuilder(),
                null,
                new FeatureRunner(new FeatureActivator(new SettingsHolder())),
                new MessageSession(new FakeRootContext()), new FakeTransportInfrastructure());

            await testee.Stop();

            Assert.That(async() => await testee.Stop(), Throws.Nothing);
        }
示例#3
0
        public async Task ShouldAllowMultipleStops()
        {
            var settings = new SettingsHolder();

            var testee = new RunningEndpointInstance(
                settings,
                new HostingComponent(null, true),
                null,
                new FeatureComponent(settings),
                new MessageSession(new FakeRootContext()),
                null);

            await testee.Stop();

            Assert.That(async() => await testee.Stop(), Throws.Nothing);
        }