Kraken\_Unit\Promise\_Partial\PromiseCancelledPartial::testApiDone_ThrowsException_WhenHandlerCancelsWithException_ForCancelledPromise PHP Метод

testApiDone_ThrowsException_WhenHandlerCancelsWithException_ForCancelledPromise() публичный Метод

    public function testApiDone_ThrowsException_WhenHandlerCancelsWithException_ForCancelledPromise()
    {
        $deferred = $this->createDeferred();
        $test = $this->getTest();
        $test->setExpectedException(Exception::class, 'CancellationException');
        $deferred->cancel(new Exception('CancellationException'));
        $test->assertNull($deferred->getPromise()->done());
    }
PromiseCancelledPartial