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

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

    public function testApiDone_InvokesCancellationHandler_ForCancelledPromise()
    {
        $deferred = $this->createDeferred();
        $test = $this->getTest();
        $mock = $test->createCallableMock();
        $mock->expects($test->once())->method('__invoke')->with($test->identicalTo(1));
        $deferred->cancel(1);
        $test->assertNull($deferred->getPromise()->done(null, null, $mock));
    }
PromiseCancelledPartial