Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The "PHPUnit\TextUI\ResultPrinter" class is considered internal #27

Closed
metalfm opened this issue Jan 21, 2020 · 3 comments
Closed

The "PHPUnit\TextUI\ResultPrinter" class is considered internal #27

metalfm opened this issue Jan 21, 2020 · 3 comments

Comments

@metalfm
Copy link

metalfm commented Jan 21, 2020

Hello,
Thank you for your package, its awesome!

Can you fix deprecation notice?

my test command

/var/www/html $ bin/phpunit --filter ArraysTest
PHPUnit 8.5.2 by Sebastian Bergmann and contributors.

Testing Project Test Suite

                       App\Tests\Common\ArraysTest ...

Time: 216 ms, Memory: 8.00 MB

OK (3 tests, 6 assertions)

Other deprecation notices (1)

  1x: The "PHPUnit\TextUI\ResultPrinter" class is considered internal This class is not covered by the backward compatibility promise for PHPUnit. It may change without further notice. You should not use it from "DiabloMedia\PHPUnit\Printer\PrettyPrinter".

Symfony version

/var/www/html $ bin/console --version
Symfony 4.4.3 (env: dev, debug: true)

Php version, run in official alpine php docker image

PHP 7.4.0 (cli) (built: Nov 28 2019 21:00:19) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
    with Zend OPcache v7.4.0, Copyright (c), by Zend Technologies
    with Xdebug v2.8.1, Copyright (c) 2002-2019, by Derick Rethans
@jaydiablo
Copy link
Member

This appears to be due to this issue in phpunit: sebastianbergmann/phpunit#3236

I see other result printer libraries with the same issue coming up:

mikeerickson/phpunit-pretty-result-printer#155
indentno/phpunit-pretty-print#28

Based on the discussion in the phpunit issue, it seems like it should be possible to request that the class become part of the public API (and the @internal doc block removed). I'll make a ticket with phpunit to see where that goes.

@jaydiablo
Copy link
Member

@metalfm See the issue I filed with PHPUnit: sebastianbergmann/phpunit#4024

There's really nothing we can do at this point, the message you're seeing is from the Symfony PHPUnit bridge apparently and not PHPUnit itself.

When PHPUnit 9.0 is released, we'll have to change this printer a little bit, but I don't think there's anything we can do for PHPUnit 8.0 aside from duplicating all of the code in PHPUnit\TextUI\ResultPrinter so the class isn't extended, which doesn't seem like a great solution.

Is there a way to ignore that notice in the symfony bridge?

@metalfm
Copy link
Author

metalfm commented Jan 29, 2020

Ok, thank you)

@metalfm metalfm closed this as completed Jan 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants