Carew\Tests\ProcessorTest::testProcessFile PHP Method

testProcessFile() public method

public testProcessFile ( )
    public function testProcessFile()
    {
        $file = new SplFileInfo(__FILE__, '', basename(__FILE__));
        $i = 0;
        $this->eventDispatcher->addListener(Events::DOCUMENT_HEADER, function () use(&$i) {
            ++$i;
        });
        $document = $this->processor->processFile($file, 'simulate-a-path');
        $this->assertSame(1, $i);
        $this->assertSame('ProcessorTest.php', $document->getPath());
        $this->assertSame('simulate-a-path/ProcessorTest.php', $document->getFilePath());
    }