eZ\Publish\Core\REST\Common\Tests\Input\ParserToolsTest::testParseObjectElementEmbedded PHP Method

testParseObjectElementEmbedded() public method

    public function testParseObjectElementEmbedded()
    {
        $parserTools = $this->getParserTools();
        $dispatcherMock = $this->getMock('eZ\\Publish\\Core\\REST\\Common\\Input\\ParsingDispatcher', array(), array(), '', false);
        $dispatcherMock->expects($this->once())->method('parse')->with($this->isType('array'), $this->equalTo('application/my-type'));
        $parsingInput = array('_href' => '/foo/bar', '_media-type' => 'application/my-type', 'someContent' => array());
        $this->assertEquals('/foo/bar', $parserTools->parseObjectElement($parsingInput, $dispatcherMock));
    }