Skip to content

Call to undefined method PHP_CodeCoverage_Filter::getInstance() #2

@maximehardy

Description

@maximehardy

Hi,

Using PHPUnit 3.6.10 and PHP_CodeCoverage 1.1.2, I was getting the following error when accessing the index.php page :
PHP Fatal error: Call to undefined method PHP_CodeCoverage_Filter::getInstance() in /var/www/vendor/PHPUnit_Html/src/main.php on line 134

I solved easily the problem by replacing the line 134 of main.php which currently is :
$filter = PHP_CodeCoverage_Filter::getInstance();
by :
$filter = new PHP_CodeCoverage_Filter();

According to the code I found on the repository of PHP_CodeCoverage, this class is not a singleton anymore, which may explain the bug.

Maxime

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions