Ejemplo n.º 1
0
 /**
  * @test
  * @expectedException \TYPO3\FLOW3\Mvc\Exception\InvalidRoutePartValueException
  */
 public function resolvesThrowsExceptionIfRoutePartDefaultValueIsNoString()
 {
     $mockRoutePart = $this->getMock('TYPO3\\FLOW3\\Mvc\\Routing\\RoutePartInterface');
     $mockRoutePart->expects($this->any())->method('resolve')->will($this->returnValue(TRUE));
     $mockRoutePart->expects($this->any())->method('hasValue')->will($this->returnValue(FALSE));
     $mockRoutePart->expects($this->once())->method('getDefaultValue')->will($this->returnValue(array('not a' => 'string')));
     $this->route->setUriPattern('foo');
     $this->route->_set('isParsed', TRUE);
     $this->route->_set('routeParts', array($mockRoutePart));
     $this->route->resolves(array());
 }