Kraken\_Unit\Channel\Extra\RequestTest::testApiRetryOrReset_RejectsPromiseInRetry_WhenRetriesLimitIsReached PHP Method

testApiRetryOrReset_RejectsPromiseInRetry_WhenRetriesLimitIsReached() public method

    public function testApiRetryOrReset_RejectsPromiseInRetry_WhenRetriesLimitIsReached()
    {
        $req = $this->createRequest($name = 'name', $mssg = 'secret', ['retriesLimit' => 0]);
        $ex = new Exception();
        $promise = new Promise();
        $callable = $this->createCallableMock();
        $callable->expects($this->once())->method('__invoke')->with($this->isInstanceOf(TimeoutException::class));
        $promise->then(null, $callable);
        $this->callProtectedMethod($req, 'retryOrReset', [$promise, $ex]);
    }