Essence\EssenceTest::testExtract PHP Method

testExtract() public method

public testExtract ( )
    public function testExtract()
    {
        $url = 'url';
        $options = [];
        $Media = new Media();
        $Extractor = $this->getMockBuilder('\\Essence\\Extractor')->disableOriginalConstructor()->getMock();
        $Extractor->expects($this->once())->method('extract')->with($this->isEqual($url), $this->isEqual($options))->will($this->returnValue($Media));
        $Essence = new Essence(['Extractor' => $Extractor]);
        $this->assertEquals($Media, $Essence->extract($url, $options));
    }