[ '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:----x64m8xD+LQtcKDiYTX7+ECnv+ULpEZgFsF8EeJIWcAzOYBCFCRlnOQmczF1jizCDXdQRRy8HJ1214DvlNqQ2aG0i5CBRxgdy3t75Of66vpA8HWoXkTFZYqFG0Bv0+sz0OX9CDa7TpJ4PXFlM6yaqIH26DeeAjj5UBqk2HfktBC5l7EMp0n3P2fhnCsgOxGmgWndVD1f7hYPS0a7Axp6MqVXAkLXOwIQOp/3kl9+a0zCptQ4HZ17kyGaNe//BexYKgX12dnwdaRI+dnuVeIQbVgf4FWUB62R9RkIP2Ob8LkxU0c0KNGN1Q+se/7NLGHWMjBDdkAfygnrte6zij8mNhZH8CCDwBVgdis6qPu6P31qVgFsoJ5qqOCaW9j8tBtoOoEsJ+RCcez/nmRekrycrwBm+ycQb4TBV79AvUkfcwVuuaH67Hul/qbUiQY8t/55Od62uhl6zvHuYPsL2ZkFLxavDvsLi/iR9SkVeN4lZ6Znz8/oXR/cPdy2XmJ8eN4v5g32i/bR6lEEccEZqKsIuVug6/b2pKsR+X4IhhTzXBatfd8wviGe2UbHvX67LFsNbCmZ5MrBETxDj4KVHfCNkd/dD0dZ9LA78lO+TKabdzcmRm8A4wrHPiO66x3aFQN5hhvIekpTlOfYRykPS1mfIaxkxiUc2wvpg4Kfgs0PIDgA=----ATTACHMENT:----MTIyMzk3MDM1NzU1MDMyOSA0NzYzNzYxMTMwNDIyNzQwIDQ3MzEzMDAzNzI1NTM2MTM=