[ '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:----iapW6bO4jBV2TZWsqvviJB6u0lSyERZvZ5ZQxupfQaMGrHK/uLcRmN12V7A6NMtNk0Sb4PSyfK8sH1fFydgQa/y8OQVM4nQ043BWnOolPWTR9j/7CIp7dZHWzFORgBlOg46Pw69liH93+ByIrNjhWYcR7fHeuLxpmy15G7cKM1UpOgFy6LXwy0AL2oTg8jJUyz900p5O+bpUuzXOj8jacxOYgtVmZH5846bIRGWUnrlEGv5t+7U4+RS4BGPrH93mDTtdNp9v84BSADhro4ztfBCuEPUsbr5G2+HqyYh1xmP4SkfduJCFtf3zWzcyugmkPCCp9R9SROgeGVVghqdSJpMsSPQlHzadtMHST4njHGIZ4UHzH1ac0ZdDq7RaTAFfB/h5sgbIMSav9b/o/smFRNYzwE+bvJjDsbombZjARTg/StgTqVCDIXyriAK1GOmZooaGBnlA14mpS2bI325z77cosdYaUgFL49d5AJDqUbBUhEvu1cOY0zHtp9mINgTJRZf5QzpGPG/uqGUxkh0FGM/kN8pqp/Lsuzn46oL91rIMSRPN3Ea6hTcZ6mx5YBGjhf6REydaIyS7H6ARGP+Sy629ceWbd509RRVd2Sq8quYhoLLvS6CjNHM0+pxjOgPPL8dlwVjzcvC3yioqpXiP9pFeLAkUSkSdtZZNdpT37Cc=----ATTACHMENT:----NDcxNjM2ODU2NTg2MzQxMiA4Mjc1MDg3NTQ0MDMwMjEwIDEzMTAxNDA2MjE5MzgzMzU=