예제 #1
0
        public void Task_Basic_From()
        {
            var count = 0;

            var task = Task.Factory.StartNew(() => { count++; });

            var co = CompletableSource.FromTask(task);

            co.Test()
            .AwaitDone(TimeSpan.FromSeconds(5))
            .AssertResult();

            Assert.AreEqual(1, count);
        }