public void EndInvoke_CompletedWithException()
        {
            object state = "STATE";
            Exception exception = new IOException();
            var target = new SftpDownloadAsyncResult(null, state);
            target.SetAsCompleted(exception, true);

            try
            {
                target.EndInvoke();
                Assert.Fail();
            }
            catch (IOException ex)
            {
                Assert.AreSame(exception, ex);
            }
        }