예제 #1
0
 public function setUp()
 {
     parent::setUp();
     $view = new Omeka_View();
     $this->helper = $view->getHelper('RecordUrl');
     $this->mockString = $this->getMock('Item', array('getRecordUrl'), array(), '', false);
     $this->mockString->expects($this->any())->method('getRecordUrl')->will($this->returnValue('/boring-url'));
     $this->mockQuery = $this->getMock('Item', array('getRecordUrl'), array(), '', false);
     $this->mockQuery->expects($this->any())->method('getRecordUrl')->will($this->returnValue('/boring-url?existing=baz'));
     $this->mockRoute = $this->getMock('Item', array('getRecordUrl'), array(), '', false);
     $this->mockRoute->expects($this->any())->method('getRecordUrl')->will($this->returnValue(array('controller' => 'items', 'action' => 'browse')));
 }