phug-php/tester

View on GitHub

Showing 93 of 93 total issues

Call to method getPath from undeclared class \Phug\Util\SourceLocationInterface
Open

            $locationPath = realpath($location->getPath());
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Call to method getCompiler from undeclared class \Phug\Renderer
Open

        $formatter = $this->renderer->getCompiler()->getFormatter();
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Call to method getOuterNode from undeclared class \Phug\Parser\NodeInterface
Open

                                $node = $node->getOuterNode() ?: $node->getParent()) {
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Argument 1 (threshold) is null but \Phug\Tester\Coverage::setThreshold() takes int defined at /code/src/Phug/Tester/Coverage.php:511
Open

        $coverage->setThreshold($coverageThreshold);
Severity: Minor
Found in src/Phug/Tester/Cli.php by phan

Call to method getOption from undeclared class \Phug\Renderer
Open

        static::emptyDirectory($this->renderer->getOption('cache_dir'));
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Checking instanceof against undeclared class \Phug\Parser\Node\DocumentNode
Open

        if ($node instanceof NodeInterface && !($node instanceof DocumentNode) && !$list->offsetExists($node)) {
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Call to method getCompiler from undeclared class \Phug\Renderer
Open

        $document = $this->renderer->getCompiler()->getParser()->parse($contents, $file);
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Checking instanceof against undeclared class \Phug\Parser\NodeInterface
Open

                                $node instanceof NodeInterface;
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Return type of getRenderer() is undeclared type \Phug\Renderer
Open

    public function getRenderer(): Renderer
Severity: Minor
Found in src/Phug/Tester/Coverage.php by phan

Argument 1 (input) is int but \str_pad() takes string
Open

                str_pad($nodes, 3, ' ', STR_PAD_LEFT).'   '.
Severity: Minor
Found in src/Phug/Tester/Coverage.php by phan

Property \Phug\Tester\TestCase->renderer has undeclared type \Phug\Renderer
Open

    protected $renderer;
Severity: Minor
Found in src/Phug/Tester/TestCaseTrait.php by phan

Return type of getRenderer() is undeclared type \Phug\Renderer
Open

    protected function getRenderer()
Severity: Minor
Found in src/Phug/Tester/TestCaseTrait.php by phan

@throws type of setUp has undeclared type \Phug\RendererException
Open

    protected function setUp(): void
Severity: Minor
Found in src/Phug/Tester/TestCaseTrait.php by phan

Static property \Phug\Tester\Coverage::$singleton is declared to have type static, but the only instance is shared among all subclasses (Did you mean \Phug\Tester\Coverage)
Open

     * @var static
Severity: Info
Found in src/Phug/Tester/Coverage.php by phan

Call to method getSourceLocation from undeclared class \Phug\Parser\NodeInterface
Open

            $this->recordLocation($node->getSourceLocation());
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Call to method getSourceLocation from undeclared class \Phug\Parser\NodeInterface
Open

                                if (!($node instanceof DocumentNode) && ($location = $node->getSourceLocation())) {
Severity: Critical
Found in src/Phug/Tester/Coverage.php by phan

Argument 1 (input) is 0|int but \str_pad() takes string
Open

                    str_pad($_coveredNodes, 3, ' ', STR_PAD_LEFT).' / '.
Severity: Minor
Found in src/Phug/Tester/Coverage.php by phan

Class extends undeclared class \PHPUnit\Framework\TestCase (Did you mean class \Phug\Tester\TestCase)
Open

abstract class TestCase extends \PHPUnit\Framework\TestCase
Severity: Critical
Found in src/Phug/Tester/TestCase.php by phan

Static call to undeclared method \ProjectExample\ViewsTest::assertContains
Open

        self::assertContains('Bar', $html);
Severity: Critical
Found in example/ViewsTest.php by phan

Static call to undeclared method \ProjectExample\ViewsTest::assertNotContains
Open

        self::assertNotContains('Foo', $html);
Severity: Critical
Found in example/ViewsTest.php by phan
Severity
Category
Status
Source
Language