Skip to content

Commit a966cc9

Browse files
committed
make ClosureDefinitionCollectorInterface optional, don't break millions of tests.
1 parent f2a4d08 commit a966cc9

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/ClientTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use Hyperf\Config\Config;
1515
use Hyperf\Contract\ConfigInterface;
1616
use Hyperf\Contract\NormalizerInterface;
17+
use Hyperf\Di\ClosureDefinitionCollectorInterface;
1718
use Hyperf\Di\Container;
1819
use Hyperf\Di\MethodDefinitionCollector;
1920
use Hyperf\Di\MethodDefinitionCollectorInterface;
@@ -70,6 +71,7 @@ public function getContainer()
7071
$container->shouldReceive('get')->with(DispatcherFactory::class)->andReturn($factory = new DispatcherFactory());
7172
$container->shouldReceive('get')->with(NormalizerInterface::class)->andReturn(new SimpleNormalizer());
7273
$container->shouldReceive('get')->with(MethodDefinitionCollectorInterface::class)->andReturn(new MethodDefinitionCollector());
74+
$container->shouldReceive('has')->with(ClosureDefinitionCollectorInterface::class)->andReturn(false);
7375
$container->shouldReceive('get')->with(ConfigInterface::class)->andReturn(new Config([
7476
'exceptions' => [
7577
'handler' => [

0 commit comments

Comments
 (0)