Composer update
This commit is contained in:
7
www/vendor/phpunit/phpunit/ChangeLog-8.5.md
vendored
7
www/vendor/phpunit/phpunit/ChangeLog-8.5.md
vendored
@@ -2,6 +2,12 @@
|
||||
|
||||
All notable changes of the PHPUnit 8.5 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles.
|
||||
|
||||
## [8.5.31] - 2022-10-28
|
||||
|
||||
### Fixed
|
||||
|
||||
* [#5076](https://github.com/sebastianbergmann/phpunit/issues/5076): Test Runner does not warn about conflicting options
|
||||
|
||||
## [8.5.30] - 2022-09-25
|
||||
|
||||
### Changed
|
||||
@@ -250,6 +256,7 @@ All notable changes of the PHPUnit 8.5 release series are documented in this fil
|
||||
* [#3967](https://github.com/sebastianbergmann/phpunit/issues/3967): Cannot double interface that extends interface that extends `\Throwable`
|
||||
* [#3968](https://github.com/sebastianbergmann/phpunit/pull/3968): Test class run in a separate PHP process are passing when `exit` called inside
|
||||
|
||||
[8.5.31]: https://github.com/sebastianbergmann/phpunit/compare/8.5.30...8.5.31
|
||||
[8.5.30]: https://github.com/sebastianbergmann/phpunit/compare/8.5.29...8.5.30
|
||||
[8.5.29]: https://github.com/sebastianbergmann/phpunit/compare/8.5.28...8.5.29
|
||||
[8.5.28]: https://github.com/sebastianbergmann/phpunit/compare/8.5.27...8.5.28
|
||||
|
||||
14
www/vendor/phpunit/phpunit/ChangeLog-9.5.md
vendored
14
www/vendor/phpunit/phpunit/ChangeLog-9.5.md
vendored
@@ -2,6 +2,18 @@
|
||||
|
||||
All notable changes of the PHPUnit 9.5 release series are documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles.
|
||||
|
||||
## [9.5.27] - 2022-12-09
|
||||
|
||||
### Fixed
|
||||
|
||||
* [#5113](https://github.com/sebastianbergmann/phpunit/pull/5113): PHP error instead of PHPUnit error when trying to create test double for `readonly` class
|
||||
|
||||
## [9.5.26] - 2022-10-28
|
||||
|
||||
### Fixed
|
||||
|
||||
* [#5076](https://github.com/sebastianbergmann/phpunit/issues/5076): Test Runner does not warn about conflicting options
|
||||
|
||||
## [9.5.25] - 2022-09-25
|
||||
|
||||
### Added
|
||||
@@ -200,6 +212,8 @@ All notable changes of the PHPUnit 9.5 release series are documented in this fil
|
||||
|
||||
* [#4535](https://github.com/sebastianbergmann/phpunit/issues/4535): `getMockFromWsdl()` does not handle methods that do not have parameters correctly
|
||||
|
||||
[9.5.27]: https://github.com/sebastianbergmann/phpunit/compare/9.5.26...9.5.27
|
||||
[9.5.26]: https://github.com/sebastianbergmann/phpunit/compare/9.5.25...9.5.26
|
||||
[9.5.25]: https://github.com/sebastianbergmann/phpunit/compare/9.5.24...9.5.25
|
||||
[9.5.24]: https://github.com/sebastianbergmann/phpunit/compare/9.5.23...9.5.24
|
||||
[9.5.23]: https://github.com/sebastianbergmann/phpunit/compare/9.5.22...9.5.23
|
||||
|
||||
2
www/vendor/phpunit/phpunit/README.md
vendored
2
www/vendor/phpunit/phpunit/README.md
vendored
@@ -1,3 +1,5 @@
|
||||
<h1 align="center">🇺🇦 <a href="https://phpunit.de/stand-with-ukraine.html">UKRAINE NEEDS YOUR HELP NOW!</a></h1>
|
||||
|
||||
# PHPUnit
|
||||
|
||||
PHPUnit is a programmer-oriented testing framework for PHP. It is an instance of the xUnit architecture for unit testing frameworks.
|
||||
|
||||
@@ -56,7 +56,7 @@ class ClassHasAttribute extends Constraint
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ final class ClassHasStaticAttribute extends ClassHasAttribute
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
28
www/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.php
vendored
Normal file
28
www/vendor/phpunit/phpunit/src/Framework/MockObject/Exception/ClassIsReadonlyException.php
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php declare(strict_types=1);
|
||||
/*
|
||||
* This file is part of PHPUnit.
|
||||
*
|
||||
* (c) Sebastian Bergmann <sebastian@phpunit.de>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
namespace PHPUnit\Framework\MockObject;
|
||||
|
||||
use function sprintf;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*/
|
||||
final class ClassIsReadonlyException extends \PHPUnit\Framework\Exception implements Exception
|
||||
{
|
||||
public function __construct(string $className)
|
||||
{
|
||||
parent::__construct(
|
||||
sprintf(
|
||||
'Class "%s" is declared "readonly" and cannot be doubled',
|
||||
$className
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -27,6 +27,7 @@ use function interface_exists;
|
||||
use function is_array;
|
||||
use function is_object;
|
||||
use function md5;
|
||||
use function method_exists;
|
||||
use function mt_rand;
|
||||
use function preg_match;
|
||||
use function preg_match_all;
|
||||
@@ -146,6 +147,7 @@ EOT;
|
||||
* @throws \PHPUnit\Framework\InvalidArgumentException
|
||||
* @throws ClassAlreadyExistsException
|
||||
* @throws ClassIsFinalException
|
||||
* @throws ClassIsReadonlyException
|
||||
* @throws DuplicateMethodException
|
||||
* @throws InvalidMethodNameException
|
||||
* @throws OriginalConstructorInvocationRequiredException
|
||||
@@ -186,7 +188,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -299,6 +301,7 @@ EOT;
|
||||
* @throws \PHPUnit\Framework\InvalidArgumentException
|
||||
* @throws ClassAlreadyExistsException
|
||||
* @throws ClassIsFinalException
|
||||
* @throws ClassIsReadonlyException
|
||||
* @throws DuplicateMethodException
|
||||
* @throws InvalidMethodNameException
|
||||
* @throws OriginalConstructorInvocationRequiredException
|
||||
@@ -317,7 +320,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -360,6 +363,7 @@ EOT;
|
||||
* @throws \PHPUnit\Framework\InvalidArgumentException
|
||||
* @throws ClassAlreadyExistsException
|
||||
* @throws ClassIsFinalException
|
||||
* @throws ClassIsReadonlyException
|
||||
* @throws DuplicateMethodException
|
||||
* @throws InvalidMethodNameException
|
||||
* @throws OriginalConstructorInvocationRequiredException
|
||||
@@ -442,6 +446,7 @@ EOT;
|
||||
|
||||
/**
|
||||
* @throws ClassIsFinalException
|
||||
* @throws ClassIsReadonlyException
|
||||
* @throws ReflectionException
|
||||
* @throws RuntimeException
|
||||
*/
|
||||
@@ -501,7 +506,7 @@ EOT;
|
||||
} catch (SoapFault $e) {
|
||||
throw new RuntimeException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -588,7 +593,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -618,7 +623,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -648,7 +653,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -678,7 +683,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -715,7 +720,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -742,7 +747,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -764,6 +769,7 @@ EOT;
|
||||
|
||||
/**
|
||||
* @throws ClassIsFinalException
|
||||
* @throws ClassIsReadonlyException
|
||||
* @throws ReflectionException
|
||||
* @throws RuntimeException
|
||||
*/
|
||||
@@ -809,7 +815,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -819,6 +825,10 @@ EOT;
|
||||
throw new ClassIsFinalException($_mockClassName['fullClassName']);
|
||||
}
|
||||
|
||||
if (method_exists($class, 'isReadOnly') && $class->isReadOnly()) {
|
||||
throw new ClassIsReadonlyException($_mockClassName['fullClassName']);
|
||||
}
|
||||
|
||||
// @see https://github.com/sebastianbergmann/phpunit/issues/2995
|
||||
if ($isInterface && $class->implementsInterface(Throwable::class)) {
|
||||
$actualClassName = Exception::class;
|
||||
@@ -831,7 +841,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -847,7 +857,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -888,7 +898,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -927,7 +937,7 @@ EOT;
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -1088,7 +1098,7 @@ EOT;
|
||||
} catch (TemplateException $e) {
|
||||
throw new RuntimeException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -114,6 +114,7 @@ final class MockBuilder
|
||||
* @throws \PHPUnit\Framework\InvalidArgumentException
|
||||
* @throws ClassAlreadyExistsException
|
||||
* @throws ClassIsFinalException
|
||||
* @throws ClassIsReadonlyException
|
||||
* @throws DuplicateMethodException
|
||||
* @throws InvalidMethodNameException
|
||||
* @throws OriginalConstructorInvocationRequiredException
|
||||
@@ -241,7 +242,7 @@ final class MockBuilder
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -283,7 +284,7 @@ final class MockBuilder
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -254,7 +254,7 @@ final class MockMethod
|
||||
} catch (TemplateException $e) {
|
||||
throw new RuntimeException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -371,7 +371,7 @@ final class MockMethod
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -554,7 +554,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -776,7 +776,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -1765,7 +1765,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -1970,6 +1970,8 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T
|
||||
* @throws \Prophecy\Exception\Doubler\InterfaceNotFoundException
|
||||
*
|
||||
* @psalm-param class-string|null $classOrInterface
|
||||
*
|
||||
* @deprecated https://github.com/sebastianbergmann/phpunit/issues/4141
|
||||
*/
|
||||
protected function prophesize(?string $classOrInterface = null): ObjectProphecy
|
||||
{
|
||||
@@ -2531,7 +2533,7 @@ abstract class TestCase extends Assert implements Reorderable, SelfDescribing, T
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -902,7 +902,7 @@ final class TestResult implements Countable
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -917,7 +917,7 @@ final class TestResult implements Countable
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -47,6 +47,8 @@ use ReflectionMethod;
|
||||
use Throwable;
|
||||
|
||||
/**
|
||||
* @template-implements IteratorAggregate<int, Test>
|
||||
*
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*/
|
||||
class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
@@ -181,7 +183,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -264,7 +266,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -319,7 +321,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -340,7 +342,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -422,7 +424,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -444,7 +446,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -464,7 +466,7 @@ class TestSuite implements IteratorAggregate, Reorderable, SelfDescribing, Test
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -14,6 +14,8 @@ use function count;
|
||||
use RecursiveIterator;
|
||||
|
||||
/**
|
||||
* @template-implements RecursiveIterator<int, Test>
|
||||
*
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*/
|
||||
final class TestSuiteIterator implements RecursiveIterator
|
||||
|
||||
@@ -76,7 +76,7 @@ final class ExtensionHandler
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ final class StandardTestSuiteLoader implements TestSuiteLoader
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -92,7 +92,7 @@ final class StandardTestSuiteLoader implements TestSuiteLoader
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ final class Version
|
||||
}
|
||||
|
||||
if (self::$version === '') {
|
||||
self::$version = (new VersionId('9.5.25', dirname(__DIR__, 2)))->getVersion();
|
||||
self::$version = (new VersionId('9.5.27', dirname(__DIR__, 2)))->getVersion();
|
||||
}
|
||||
|
||||
return self::$version;
|
||||
@@ -60,6 +60,6 @@ final class Version
|
||||
|
||||
public static function getVersionString(): string
|
||||
{
|
||||
return 'PHPUnit ' . self::id() . ' #StandWithUkraine';
|
||||
return 'PHPUnit ' . self::id() . ' by Sebastian Bergmann and contributors.';
|
||||
}
|
||||
}
|
||||
|
||||
@@ -135,7 +135,7 @@ final class Builder
|
||||
} catch (CliParserException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
102
www/vendor/phpunit/phpunit/src/TextUI/Command.php
vendored
102
www/vendor/phpunit/phpunit/src/TextUI/Command.php
vendored
@@ -452,7 +452,7 @@ class Command
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -522,7 +522,7 @@ class Command
|
||||
} catch (\ReflectionException $e) {
|
||||
throw new ReflectionException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
// @codeCoverageIgnoreEnd
|
||||
@@ -641,6 +641,16 @@ class Command
|
||||
{
|
||||
$this->printVersionString();
|
||||
|
||||
$this->warnAboutConflictingOptions(
|
||||
'listGroups',
|
||||
[
|
||||
'filter',
|
||||
'groups',
|
||||
'excludeGroups',
|
||||
'testsuite',
|
||||
]
|
||||
);
|
||||
|
||||
print 'Available test group(s):' . PHP_EOL;
|
||||
|
||||
$groups = $suite->getGroups();
|
||||
@@ -672,6 +682,16 @@ class Command
|
||||
{
|
||||
$this->printVersionString();
|
||||
|
||||
$this->warnAboutConflictingOptions(
|
||||
'listSuites',
|
||||
[
|
||||
'filter',
|
||||
'groups',
|
||||
'excludeGroups',
|
||||
'testsuite',
|
||||
]
|
||||
);
|
||||
|
||||
print 'Available test suite(s):' . PHP_EOL;
|
||||
|
||||
foreach ($this->arguments['configurationObject']->testSuite() as $testSuite) {
|
||||
@@ -695,6 +715,16 @@ class Command
|
||||
{
|
||||
$this->printVersionString();
|
||||
|
||||
$this->warnAboutConflictingOptions(
|
||||
'listTests',
|
||||
[
|
||||
'filter',
|
||||
'groups',
|
||||
'excludeGroups',
|
||||
'testsuite',
|
||||
]
|
||||
);
|
||||
|
||||
$renderer = new TextTestListRenderer;
|
||||
|
||||
print $renderer->render($suite);
|
||||
@@ -713,6 +743,16 @@ class Command
|
||||
{
|
||||
$this->printVersionString();
|
||||
|
||||
$this->warnAboutConflictingOptions(
|
||||
'listTestsXml',
|
||||
[
|
||||
'filter',
|
||||
'groups',
|
||||
'excludeGroups',
|
||||
'testsuite',
|
||||
]
|
||||
);
|
||||
|
||||
$renderer = new XmlTestListRenderer;
|
||||
|
||||
file_put_contents($target, $renderer->render($suite));
|
||||
@@ -905,4 +945,62 @@ class Command
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @psalm-param "listGroups"|"listSuites"|"listTests"|"listTestsXml"|"filter"|"groups"|"excludeGroups"|"testsuite" $key
|
||||
* @psalm-param list<"listGroups"|"listSuites"|"listTests"|"listTestsXml"|"filter"|"groups"|"excludeGroups"|"testsuite"> $keys
|
||||
*/
|
||||
private function warnAboutConflictingOptions(string $key, array $keys): void
|
||||
{
|
||||
$warningPrinted = false;
|
||||
|
||||
foreach ($keys as $_key) {
|
||||
if (!empty($this->arguments[$_key])) {
|
||||
printf(
|
||||
'The %s and %s options cannot be combined, %s is ignored' . PHP_EOL,
|
||||
$this->mapKeyToOptionForWarning($_key),
|
||||
$this->mapKeyToOptionForWarning($key),
|
||||
$this->mapKeyToOptionForWarning($_key)
|
||||
);
|
||||
|
||||
$warningPrinted = true;
|
||||
}
|
||||
}
|
||||
|
||||
if ($warningPrinted) {
|
||||
print PHP_EOL;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @psalm-param "listGroups"|"listSuites"|"listTests"|"listTestsXml"|"filter"|"groups"|"excludeGroups"|"testsuite" $key
|
||||
*/
|
||||
private function mapKeyToOptionForWarning(string $key): string
|
||||
{
|
||||
switch ($key) {
|
||||
case 'listGroups':
|
||||
return '--list-groups';
|
||||
|
||||
case 'listSuites':
|
||||
return '--list-suites';
|
||||
|
||||
case 'listTests':
|
||||
return '--list-tests';
|
||||
|
||||
case 'listTestsXml':
|
||||
return '--list-tests-xml';
|
||||
|
||||
case 'filter':
|
||||
return '--filter';
|
||||
|
||||
case 'groups':
|
||||
return '--group';
|
||||
|
||||
case 'excludeGroups':
|
||||
return '--exclude-group';
|
||||
|
||||
case 'testsuite':
|
||||
return '--testsuite';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,7 +54,6 @@ use PHPUnit\TextUI\XmlConfiguration\CodeCoverage\FilterMapper;
|
||||
use PHPUnit\TextUI\XmlConfiguration\Configuration;
|
||||
use PHPUnit\TextUI\XmlConfiguration\Loader;
|
||||
use PHPUnit\TextUI\XmlConfiguration\PhpHandler;
|
||||
use PHPUnit\Util\Color;
|
||||
use PHPUnit\Util\Filesystem;
|
||||
use PHPUnit\Util\Log\JUnit;
|
||||
use PHPUnit\Util\Log\TeamCity;
|
||||
@@ -308,7 +307,7 @@ final class TestRunner extends BaseTestRunner
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -326,18 +325,7 @@ final class TestRunner extends BaseTestRunner
|
||||
$this->printer->setShowProgressAnimation(!$arguments['noInteraction']);
|
||||
}
|
||||
|
||||
if ($arguments['colors'] !== DefaultResultPrinter::COLOR_NEVER) {
|
||||
$this->write(
|
||||
'PHPUnit ' .
|
||||
Version::id() .
|
||||
' ' .
|
||||
Color::colorize('bg-blue,fg-white', '#StandWith') .
|
||||
Color::colorize('bg-yellow,fg-black', 'Ukraine') .
|
||||
"\n"
|
||||
);
|
||||
} else {
|
||||
$this->write(Version::getVersionString() . "\n");
|
||||
}
|
||||
$this->write(Version::getVersionString() . "\n");
|
||||
|
||||
foreach ($arguments['listeners'] as $listener) {
|
||||
$result->addListener($listener);
|
||||
|
||||
@@ -95,7 +95,7 @@ final class TestSuiteMapper
|
||||
} catch (FrameworkException $e) {
|
||||
throw new RuntimeException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, Directory>
|
||||
*/
|
||||
final class DirectoryCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, Directory>
|
||||
*/
|
||||
final class DirectoryCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, Directory>
|
||||
*/
|
||||
final class DirectoryCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, Directory>
|
||||
*/
|
||||
final class DirectoryCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, File>
|
||||
*/
|
||||
final class FileCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, File>
|
||||
*/
|
||||
final class FileCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -15,6 +15,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, Group>
|
||||
*/
|
||||
final class GroupCollection implements IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, Group>
|
||||
*/
|
||||
final class GroupCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -72,7 +72,7 @@ final class Loader
|
||||
} catch (XmlException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -84,7 +84,7 @@ final class Loader
|
||||
} catch (XmlException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
*/
|
||||
namespace PHPUnit\TextUI\XmlConfiguration;
|
||||
|
||||
use function assert;
|
||||
use DOMDocument;
|
||||
use DOMElement;
|
||||
use PHPUnit\Util\Xml\SnapshotNodeList;
|
||||
@@ -27,6 +28,8 @@ final class RemoveLogTypes implements Migration
|
||||
}
|
||||
|
||||
foreach (SnapshotNodeList::fromNodeList($logging->getElementsByTagName('log')) as $logNode) {
|
||||
assert($logNode instanceof DOMElement);
|
||||
|
||||
switch ($logNode->getAttribute('type')) {
|
||||
case 'json':
|
||||
case 'tap':
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, Constant>
|
||||
*/
|
||||
final class ConstantCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, Constant>
|
||||
*/
|
||||
final class ConstantCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, IniSetting>
|
||||
*/
|
||||
final class IniSettingCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, IniSetting>
|
||||
*/
|
||||
final class IniSettingCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, Variable>
|
||||
*/
|
||||
final class VariableCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, Variable>
|
||||
*/
|
||||
final class VariableCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -15,6 +15,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, Extension>
|
||||
*/
|
||||
final class ExtensionCollection implements IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, Extension>
|
||||
*/
|
||||
final class ExtensionCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, TestDirectory>
|
||||
*/
|
||||
final class TestDirectoryCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, TestDirectory>
|
||||
*/
|
||||
final class TestDirectoryCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, TestFile>
|
||||
*/
|
||||
final class TestFileCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, TestFile>
|
||||
*/
|
||||
final class TestFileCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -17,6 +17,8 @@ use IteratorAggregate;
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @psalm-immutable
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, TestSuite>
|
||||
*/
|
||||
final class TestSuiteCollection implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
@@ -16,6 +16,8 @@ use Iterator;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements Iterator<int, TestSuite>
|
||||
*/
|
||||
final class TestSuiteCollectionIterator implements Countable, Iterator
|
||||
{
|
||||
|
||||
@@ -410,7 +410,7 @@ final class DocBlock
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
// @codeCoverageIgnoreEnd
|
||||
|
||||
@@ -58,7 +58,7 @@ final class Registry
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -84,7 +84,7 @@ final class Registry
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -292,7 +292,7 @@ final class JUnit extends Printer implements TestListener
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -307,7 +307,7 @@ final class JUnit extends Printer implements TestListener
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -366,7 +366,7 @@ final class TeamCity extends DefaultResultPrinter
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
2
www/vendor/phpunit/phpunit/src/Util/Test.php
vendored
2
www/vendor/phpunit/phpunit/src/Util/Test.php
vendored
@@ -659,7 +659,7 @@ final class Test
|
||||
$mode,
|
||||
$element
|
||||
),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -242,7 +242,7 @@ final class NamePrettifier
|
||||
} catch (ReflectionException $e) {
|
||||
throw new UtilException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
@@ -262,7 +262,7 @@ final class NamePrettifier
|
||||
} catch (ReflectionException $e) {
|
||||
throw new UtilException(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -239,7 +239,7 @@ final class XmlResultPrinter extends Printer implements TestListener
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
2
www/vendor/phpunit/phpunit/src/Util/Xml.php
vendored
2
www/vendor/phpunit/phpunit/src/Util/Xml.php
vendored
@@ -126,7 +126,7 @@ final class Xml
|
||||
} catch (ReflectionException $e) {
|
||||
throw new Exception(
|
||||
$e->getMessage(),
|
||||
(int) $e->getCode(),
|
||||
$e->getCode(),
|
||||
$e
|
||||
);
|
||||
}
|
||||
|
||||
@@ -18,6 +18,8 @@ use IteratorAggregate;
|
||||
|
||||
/**
|
||||
* @internal This class is not covered by the backward compatibility promise for PHPUnit
|
||||
*
|
||||
* @template-implements IteratorAggregate<int, DOMNode>
|
||||
*/
|
||||
final class SnapshotNodeList implements Countable, IteratorAggregate
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user