Skip to content

Commit

Permalink
Reorganize
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastianbergmann committed Apr 2, 2023
1 parent 2eb91e4 commit 9e60ead
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Framework/TestRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
use PHPUnit\Metadata\Api\CodeCoverage as CodeCoverageMetadataApi;
use PHPUnit\Metadata\Parser\Registry as MetadataRegistry;
use PHPUnit\Runner\CodeCoverage;
use PHPUnit\Runner\ErrorHandler;
use PHPUnit\TextUI\Configuration\Configuration;
use PHPUnit\TextUI\Configuration\Registry as ConfigurationRegistry;
use PHPUnit\Util\ErrorHandler;
use PHPUnit\Util\GlobalState;
use PHPUnit\Util\PHP\AbstractPhpProcess;
use ReflectionClass;
Expand Down
4 changes: 2 additions & 2 deletions src/Util/ErrorHandler.php → src/Runner/ErrorHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Util;
namespace PHPUnit\Runner;

This comment has been minimized.

Copy link
@alexislefebvre

alexislefebvre Apr 19, 2023

This break some implementations that used this namespace.

Upgrading from PHPUnit 10.0 to 10.1 gives me this:

TypeError: call_user_func(): Argument #1 ($callback) must be a valid callback, class "PHPUnit\Util\ErrorHandler" not found

Can we provide a (deprecated) alias?

This comment has been minimized.

Copy link
@sebastianbergmann

sebastianbergmann Apr 20, 2023

Author Owner

No. This class is marked @internal and is not covered by the backward compatibility promise for PHPUnit. When you rely on PHPUnit's internals then you are on your own.

This comment has been minimized.

Copy link
@alexislefebvre

alexislefebvre Apr 20, 2023

My bad, I'm sorry I missed that. Thanks for your answer.


use const E_DEPRECATED;
use const E_NOTICE;
Expand Down Expand Up @@ -38,7 +38,7 @@ public static function instance(): self
}

/**
* @throws Exception
* @throws NoTestCaseObjectOnCallStackException
*/
public function __invoke(int $errorNumber, string $errorString, string $errorFile, int $errorLine): bool
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace PHPUnit\Util;
namespace PHPUnit\Runner;

use RuntimeException;

Expand Down

0 comments on commit 9e60ead

Please sign in to comment.