Esempio n. 1
0
 public function testGetlistMethodShouldReturnArrayOfProjectObjects()
 {
     $ProjectService = new Project_Service_Project();
     $result = $ProjectService->getList();
     $this->assertInternalType('array', $result);
     if (is_array($result)) {
         $isProjectObject = true;
         foreach ($result as $project) {
             if (!$project instanceof Project_Model_Project) {
                 $isProjectObject = false;
             }
         }
         $this->assertTrue($isProjectObject);
     }
 }
Esempio n. 2
0
 public function listAction()
 {
     $projectService = new Project_Service_Project();
     $this->view->projects = $projectService->getList();
 }