private function generateLocationMock() { $location = $this->getLocationMock(); $location->expects($this->any())->method('getContentInfo')->will($this->returnValue($this->getContentInfoMock(array('contentTypeId' => 42)))); return $location; }