コード例 #1
0
 public function testSessionCreation()
 {
     $factory = new SessionFactory();
     $this->assertInstanceof('Zend\\ServiceManager\\FactoryInterface', $factory);
     $servicemanager = Bootstrap::getServiceManager();
     $session = $factory->createService($servicemanager);
     $this->assertInstanceof('\\Zend\\Session\\Container', $session);
 }
コード例 #2
0
 public function testSessionCreation()
 {
     $factory = new HybridAuthFactory();
     $this->assertInstanceof('Zend\\ServiceManager\\FactoryInterface', $factory);
     $servicemanager = Bootstrap::getServiceManager();
     $_SERVER['SERVER_NAME'] = 'localhost';
     $_SERVER['REQUEST_URI'] = 'http://localhost';
     $_SERVER['HTTP_HOST'] = 'localhost';
     $this->markTestIncomplete('Testing inomplete due to routing issues');
     //        $servicemanager->get('router')->addRoute('hybridauth/backend',array('options'=> array('route'=>'test')));
     //        $authInst = $factory->createService($servicemanager);
     //        $this->assertInstanceof('\Hybrid_Auth', $authInst);
 }
コード例 #3
0
 public function testSessionCreation()
 {
     $factory = new IndexControllerFactory();
     $this->assertInstanceof('Zend\\ServiceManager\\FactoryInterface', $factory);
     $servicemanager = Bootstrap::getServiceManager();
     $_SERVER['SERVER_NAME'] = 'localhost';
     $_SERVER['REQUEST_URI'] = 'http://localhost';
     $_SERVER['HTTP_HOST'] = 'localhost';
     $this->markTestIncomplete('Testing inomplete due to routing issues');
     //        $controller = $factory->createService($servicemanager);
     //        $this->assertInstanceof('\OrgHeiglHybridAuth\Controller\IndexController', $controller);
     //        $this->assertAttributeEquals($servicemanager->get('OrgHeiglHybridAuthSession'), 'session', $controller);
     //        $this->assertAttributeEquals($servicemanager->get('OrgHeiglHybridAuthBackend'), 'authenticator', $controller);
     //        $this->assertAttributeEquals($servicemanager->get('OrgHeiglHybridAuth\UserWrapperFactory'), 'userWrapperFactory', $controller);
 }