Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.x - Remove DeferredCallable #2811

Merged
merged 2 commits into from Aug 18, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
46 changes: 0 additions & 46 deletions Slim/DeferredCallable.php

This file was deleted.

71 changes: 0 additions & 71 deletions tests/DeferredCallableTest.php

This file was deleted.

6 changes: 2 additions & 4 deletions tests/Routing/RouteTest.php
Expand Up @@ -17,10 +17,8 @@
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Message\StreamInterface;
use Psr\Http\Message\UriInterface;
use Psr\Http\Server\RequestHandlerInterface;
use Slim\CallableResolver;
use Slim\DeferredCallable;
use Slim\Handlers\Strategies\RequestHandler;
use Slim\Handlers\Strategies\RequestResponse;
use Slim\Interfaces\CallableResolverInterface;
Expand Down Expand Up @@ -390,7 +388,7 @@ public function testControllerMethodAsStringResolvesWithoutContainer()
$callableResolver = new CallableResolver();
$responseFactory = $this->getResponseFactory();

$deferred = new DeferredCallable('\Slim\Tests\Mocks\CallableTest:toCall', $callableResolver);
$deferred = $callableResolver->resolve('\Slim\Tests\Mocks\CallableTest:toCall');
$route = new Route(['GET'], '/', $deferred, $responseFactory, $callableResolver);

CallableTest::$CalledCount = 0;
Expand All @@ -410,7 +408,6 @@ public function testControllerMethodAsStringResolvesWithContainer()
$callableResolverProphecy = $this->prophesize(CallableResolverInterface::class);

$callable = 'CallableTest:toCall';
$deferred = new DeferredCallable($callable, $callableResolverProphecy->reveal());

$callableResolverProphecy
->resolve($callable)
Expand All @@ -426,6 +423,7 @@ public function testControllerMethodAsStringResolvesWithContainer()
})
->shouldBeCalledOnce();

$deferred = $callableResolverProphecy->reveal()->resolve($callable);
$callableResolverProphecy
->resolve($deferred)
->willReturn($deferred)
Expand Down