Example #1
0
        public void ServiceNamesTest()
        {
            using (IGridionService distributedCollectionService = new DistributedCollectionService())
            {
                Assert.AreEqual("DistributedCollectionService", distributedCollectionService.Name);
            }

            using (IGridionService outMessengerService = new MemoryMessengerService())
            {
                Assert.AreEqual("MemoryMessengerService", outMessengerService.Name);
            }
        }
Example #2
0
        public void ServiceNamesTest()
        {
            using (IGridionService distributedCollectionService = new DistributedCollectionService())
            {
                Assert.AreEqual("DistributedCollectionService", distributedCollectionService.Name);
            }

            var clusterCurator = Substitute.For <IClusterCurator>();

            using (IGridionService outMessengerService = new MemoryMessengerService(clusterCurator))
            {
                Assert.AreEqual("MemoryMessengerService", outMessengerService.Name);
            }
        }
Example #3
0
        public void StartStopTest()
        {
            using (IGridionService distributedCollectionService = new DistributedCollectionService())
            {
                using (IGridionService messengerService = new MemoryMessengerService())
                {
                    distributedCollectionService.Start();
                    messengerService.Start();

                    Assert.IsTrue(distributedCollectionService.IsRunning);
                    Assert.IsTrue(messengerService.IsRunning);

                    distributedCollectionService.Stop();
                    messengerService.Stop();

                    Assert.IsFalse(distributedCollectionService.IsRunning);
                    Assert.IsFalse(messengerService.IsRunning);
                }
            }
        }
Example #4
0
        public void StartStopTest()
        {
            using (IGridionService distributedCollectionService = new DistributedCollectionService())
            {
                var clusterCurator = Substitute.For <IClusterCurator>();
                using (IGridionService messengerService = new MemoryMessengerService(clusterCurator))
                {
                    distributedCollectionService.Start();
                    messengerService.Start();

                    Assert.IsTrue(distributedCollectionService.IsRunning);
                    Assert.IsTrue(messengerService.IsRunning);

                    distributedCollectionService.Stop();
                    messengerService.Stop();

                    Assert.IsFalse(distributedCollectionService.IsRunning);
                    Assert.IsFalse(messengerService.IsRunning);
                }
            }
        }