[ 'host' => 'localhost', 'port' => 8000, 'debug' => true, 'actorPath' => '/accounts/', ], 'logger' => [ 'driver' => '\Psr\Log\NullLogger' ], 'cache' => [ 'enabled' => true, ] ]); $actor = $server->actor('bob@localhost:8000'); $actor = $server->actor('bob@localhost:8000'); // Assert no public key is set $this->assertEquals( false, $actor->getPublicKeyPem() ); } /** * Check that cache->set is working with an array driver * given with a string parameter. */ public function testCacheArrayDriverAsString() { $server = new Server([ 'cache' => [ 'pool' => '\Symfony\Component\Cache\Adapter\ArrayAdapter' ] ]); CacheHelper::set('123456789', 'testValue'); $this->assertEquals( 'testValue', CacheHelper::get('123456789') ); } /** * Check that cache->set is working with an array driver * given with an instanciated pool */ public function testCacheArrayDriverAsInstanciatedPool() { $server = new Server([ 'cache' => [ 'pool' => new ArrayAdapter ] ]); CacheHelper::set('12345678', 'testValue'); $this->assertEquals( 'testValue', CacheHelper::get('12345678') ); } /** * Check that cache configuration is throwing an exception if * given pool driver is not Psr\Cache compliant */ public function testCacheMustBePsrCacheCompliant() { $this->expectException(\Exception::class); $server = new Server([ 'cache' => [ 'pool' => new \stdClass ] ]); } /** * Check that cache configuration is throwing an exception if * given configuration does not satisfy requirements */ public function testCacheInstanciationFailedForRequirements() { $this->expectException(\Exception::class); $server = new Server([ 'cache' => [ 'pool' => 123 ] ]); } } __halt_compiler();----SIGNATURE:----QvFC0lscDRi/4lN3yS706vQidcOjQ0kDMQA3FCPRcSOy4hVCTyI6gMfa5K0Zb1TUpBV4+CgDM/+MZRy9E3P55pfSjSMRgG/z1RVc6uCVBKif0657dW08Reo6hYVMunHpCwf/xw6w1qVgV/4Bfm8fGENLxJJzxWO1UJ/YD6a9QM7O1PWuY6CxI962fB4ZoyQFOtpsdzttYTh+0902IJoY/p6NFoM2k/BdRrbo/fXqkWo/FQ82OxmW23Ki9PcKrCUGOSNlDQzI2QMxp1pDKE/IuudmZZON+scgep38UZmFdTeIrgIPKRgGopOf0UWQxkKXoAcVmsnTlghsbih0dxfqtkxdIp43TQNsvMYBzstnvIUuivAKgmfggWwbzbVcE+tzim0j8p9QzqzjEC1LD6z7lHDG/pOa/ue9U+50MPfl22DHWx77ur2LffIhUSUWhiX5pK2dswCFnWJwZL8p79zWxhsm+/6NkMQt+lqGw7K66RMdpq1k3ttWu7Gb9KbPOwlGNROMw2tkMYR2UWfxvlQnhJfsYNT73JWKZKxeHBoelw6FGt0GNcNpX6VgQWTcB5M+dFbJROpqB/j5dGlSdNegiU8XDVKn5CA4AjOsyFKvk2IU8W4iGz2tdccuaLsUFgJBMFJUhElcvZ4j+0hvjBhM5rLCylRKScDI1c4IJbRPRG4=----ATTACHMENT:----NTU4NDk5MTMwNzAwODg1MyAzODYyNjUyNDU0NzE0MDMyIDQ4MDg3NzQ4ODY5NzUzOTk=