public void TestUnexpectedException()
        {
            var service = new NaiveAsyncService();
            var task    = service.DoLongRunningTask().Promise().Then(() => { throw new NotImplementedException(); });

            Assert(!task.Check());

            service.Resolve();
            Assert(task.Check());
        }
        public void TestHandleNaiveTask()
        {
            var resolved = false;
            var service  = new NaiveAsyncService();
            var task     = service.DoLongRunningTask().Promise().Then(() => { resolved = true; });

            Assert(!task.Check());

            service.Resolve();
            Assert(task.Check());
            Assert(resolved);
        }