Beispiel #1
0
        public void TestRpcContinuationQueueEnqueueAndRelease()
        {
            RpcContinuationQueue queue = new RpcContinuationQueue();
            var inputContinuation      = new SimpleBlockingRpcContinuation();

            queue.Enqueue(inputContinuation);
            IRpcContinuation outputContinuation = queue.Next();

            Assert.AreEqual(outputContinuation, inputContinuation);
        }
Beispiel #2
0
        public void TestRpcContinuationQueueEnqueue2()
        {
            RpcContinuationQueue queue = new RpcContinuationQueue();
            var inputContinuation      = new SimpleBlockingRpcContinuation();
            var inputContinuation1     = new SimpleBlockingRpcContinuation();

            queue.Enqueue(inputContinuation);
            Assert.Throws(typeof(NotSupportedException), () =>
            {
                queue.Enqueue(inputContinuation1);
            });
        }