コード例 #1
0
		/// <exception cref="System.Exception"></exception>
		public virtual void Test()
		{
			if (IsEmbedded())
			{
				// This test really doesn't make sense for MTOC, there
				// is no client to ping.
				return;
			}
			IServerMessageDispatcher dispatcher = ServerDispatcher();
			ClientServerPingTestCase.PingThread pingThread = new ClientServerPingTestCase.PingThread
				(dispatcher);
			pingThread.Start();
			for (int i = 0; i < ItemCount; i++)
			{
				ClientServerPingTestCase.Item item = new ClientServerPingTestCase.Item(i);
				Store(item);
			}
			Assert.AreEqual(ItemCount, Db().QueryByExample(typeof(ClientServerPingTestCase.Item
				)).Count);
			pingThread.Close();
		}
コード例 #2
0
        /// <exception cref="System.Exception"></exception>
        public virtual void Test()
        {
            if (IsEmbedded())
            {
                // This test really doesn't make sense for MTOC, there
                // is no client to ping.
                return;
            }
            IServerMessageDispatcher dispatcher = ServerDispatcher();

            ClientServerPingTestCase.PingThread pingThread = new ClientServerPingTestCase.PingThread
                                                                 (dispatcher);
            pingThread.Start();
            for (int i = 0; i < ItemCount; i++)
            {
                ClientServerPingTestCase.Item item = new ClientServerPingTestCase.Item(i);
                Store(item);
            }
            Assert.AreEqual(ItemCount, Db().QueryByExample(typeof(ClientServerPingTestCase.Item
                                                                  )).Count);
            pingThread.Close();
        }