public function setUp()
 {
     $manifest = new Manifest(['models' => [__NAMESPACE__ . '\\TestAsset\\Document' => __DIR__ . '/TestAsset/Document'], 'extension_configs' => ['extension.accesscontrol' => true, 'extension.owner' => true, 'extension.odmcore' => true], 'service_manager_config' => ['factories' => ['user' => function () {
         $user = new RoleAwareUser();
         $user->setUsername('toby');
         return $user;
     }]]]);
     $this->documentManager = $manifest->getServiceManager()->get('modelmanager');
 }
Example #2
0
 public function setUp()
 {
     $manifest = new Manifest(['service_manager_config' => ['factories' => ['user' => function () {
         $user = new RoleAwareUser();
         $user->setUsername('toby');
         return $user;
     }]]]);
     $this->user = $manifest->getServiceManager()->get('user');
 }