Esempio n. 1
0
 /**
  * Locates a view file
  *
  * @param string $name
  *
  * @return string|null Path to file
  */
 public function findView($name)
 {
     if (file_exists($name)) {
         return $name;
     }
     return $this->viewManager->findView($name);
 }
Esempio n. 2
0
 /**
  * @covers ::findView
  */
 public function testFindView()
 {
     $this->finderMock->shouldReceive('findFileReversed')->with('views/file.php')->andReturn('views/file.php')->once();
     $this->assertEquals('views/file.php', $this->viewManager->findView('file.php'));
 }