mirror of
https://github.com/rectorphp/rector.git
synced 2024-06-11 05:32:23 +00:00
Updated Rector to commit 06cb6754d6f04703093905fbaddbbbe4f9546a22
06cb6754d6
move package ci status directly to README to make easier to discovery
This commit is contained in:
parent
afd435c4e5
commit
d2a6e3f136
|
@ -17,12 +17,12 @@ final class VersionResolver
|
|||
* @api
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGE_VERSION = '0f0d93ec97edfcdca58f0f5b65e9b7b578f19f60';
|
||||
public const PACKAGE_VERSION = '06cb6754d6f04703093905fbaddbbbe4f9546a22';
|
||||
/**
|
||||
* @api
|
||||
* @var string
|
||||
*/
|
||||
public const RELEASE_DATE = '2022-12-03 11:35:58';
|
||||
public const RELEASE_DATE = '2022-12-03 11:46:43';
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
|
|
2
vendor/autoload.php
vendored
2
vendor/autoload.php
vendored
|
@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) {
|
|||
|
||||
require_once __DIR__ . '/composer/autoload_real.php';
|
||||
|
||||
return ComposerAutoloaderInit450137aec28b4099823df530616baf1c::getLoader();
|
||||
return ComposerAutoloaderInit5424342770688078c8dad80f32ef58ea::getLoader();
|
||||
|
|
14
vendor/composer/autoload_real.php
vendored
14
vendor/composer/autoload_real.php
vendored
|
@ -2,7 +2,7 @@
|
|||
|
||||
// autoload_real.php @generated by Composer
|
||||
|
||||
class ComposerAutoloaderInit450137aec28b4099823df530616baf1c
|
||||
class ComposerAutoloaderInit5424342770688078c8dad80f32ef58ea
|
||||
{
|
||||
private static $loader;
|
||||
|
||||
|
@ -22,19 +22,19 @@ class ComposerAutoloaderInit450137aec28b4099823df530616baf1c
|
|||
return self::$loader;
|
||||
}
|
||||
|
||||
spl_autoload_register(array('ComposerAutoloaderInit450137aec28b4099823df530616baf1c', 'loadClassLoader'), true, true);
|
||||
spl_autoload_register(array('ComposerAutoloaderInit5424342770688078c8dad80f32ef58ea', 'loadClassLoader'), true, true);
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit450137aec28b4099823df530616baf1c', 'loadClassLoader'));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit5424342770688078c8dad80f32ef58ea', 'loadClassLoader'));
|
||||
|
||||
require __DIR__ . '/autoload_static.php';
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit450137aec28b4099823df530616baf1c::getInitializer($loader));
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit5424342770688078c8dad80f32ef58ea::getInitializer($loader));
|
||||
|
||||
$loader->setClassMapAuthoritative(true);
|
||||
$loader->register(true);
|
||||
|
||||
$includeFiles = \Composer\Autoload\ComposerStaticInit450137aec28b4099823df530616baf1c::$files;
|
||||
$includeFiles = \Composer\Autoload\ComposerStaticInit5424342770688078c8dad80f32ef58ea::$files;
|
||||
foreach ($includeFiles as $fileIdentifier => $file) {
|
||||
composerRequire450137aec28b4099823df530616baf1c($fileIdentifier, $file);
|
||||
composerRequire5424342770688078c8dad80f32ef58ea($fileIdentifier, $file);
|
||||
}
|
||||
|
||||
return $loader;
|
||||
|
@ -46,7 +46,7 @@ class ComposerAutoloaderInit450137aec28b4099823df530616baf1c
|
|||
* @param string $file
|
||||
* @return void
|
||||
*/
|
||||
function composerRequire450137aec28b4099823df530616baf1c($fileIdentifier, $file)
|
||||
function composerRequire5424342770688078c8dad80f32ef58ea($fileIdentifier, $file)
|
||||
{
|
||||
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
||||
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
|
||||
|
|
8
vendor/composer/autoload_static.php
vendored
8
vendor/composer/autoload_static.php
vendored
|
@ -4,7 +4,7 @@
|
|||
|
||||
namespace Composer\Autoload;
|
||||
|
||||
class ComposerStaticInit450137aec28b4099823df530616baf1c
|
||||
class ComposerStaticInit5424342770688078c8dad80f32ef58ea
|
||||
{
|
||||
public static $files = array (
|
||||
'ad155f8f1cf0d418fe49e248db8c661b' => __DIR__ . '/..' . '/react/promise/src/functions_include.php',
|
||||
|
@ -3023,9 +3023,9 @@ class ComposerStaticInit450137aec28b4099823df530616baf1c
|
|||
public static function getInitializer(ClassLoader $loader)
|
||||
{
|
||||
return \Closure::bind(function () use ($loader) {
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit450137aec28b4099823df530616baf1c::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit450137aec28b4099823df530616baf1c::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInit450137aec28b4099823df530616baf1c::$classMap;
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit5424342770688078c8dad80f32ef58ea::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit5424342770688078c8dad80f32ef58ea::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInit5424342770688078c8dad80f32ef58ea::$classMap;
|
||||
|
||||
}, null, ClassLoader::class);
|
||||
}
|
||||
|
|
10
vendor/composer/installed.json
vendored
10
vendor/composer/installed.json
vendored
|
@ -1989,12 +1989,12 @@
|
|||
"source": {
|
||||
"type": "git",
|
||||
"url": "https:\/\/github.com\/rectorphp\/rector-phpunit.git",
|
||||
"reference": "e646c56c4847d941eb656d18c8a047c9441b2de6"
|
||||
"reference": "3d0d84d78aed4aa4ca9a8e3eae3f51dcb833beb7"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-phpunit\/zipball\/e646c56c4847d941eb656d18c8a047c9441b2de6",
|
||||
"reference": "e646c56c4847d941eb656d18c8a047c9441b2de6",
|
||||
"url": "https:\/\/api.github.com\/repos\/rectorphp\/rector-phpunit\/zipball\/3d0d84d78aed4aa4ca9a8e3eae3f51dcb833beb7",
|
||||
"reference": "3d0d84d78aed4aa4ca9a8e3eae3f51dcb833beb7",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -2020,7 +2020,7 @@
|
|||
"symplify\/rule-doc-generator": "^11.1",
|
||||
"symplify\/vendor-patches": "^11.1"
|
||||
},
|
||||
"time": "2022-11-25T15:00:47+00:00",
|
||||
"time": "2022-12-03T10:43:12+00:00",
|
||||
"default-branch": true,
|
||||
"type": "rector-extension",
|
||||
"extra": {
|
||||
|
@ -2047,7 +2047,7 @@
|
|||
"description": "Rector upgrades rules for PHPUnit",
|
||||
"support": {
|
||||
"issues": "https:\/\/github.com\/rectorphp\/rector-phpunit\/issues",
|
||||
"source": "https:\/\/github.com\/rectorphp\/rector-phpunit\/tree\/main"
|
||||
"source": "https:\/\/github.com\/rectorphp\/rector-phpunit\/tree\/0.14.1"
|
||||
},
|
||||
"install-path": "..\/rector\/rector-phpunit"
|
||||
},
|
||||
|
|
2
vendor/composer/installed.php
vendored
2
vendor/composer/installed.php
vendored
File diff suppressed because one or more lines are too long
|
@ -9,7 +9,7 @@ namespace Rector\RectorInstaller;
|
|||
*/
|
||||
final class GeneratedConfig
|
||||
{
|
||||
public const EXTENSIONS = array('rector/rector-doctrine' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-doctrine', 'relative_install_path' => '../../rector-doctrine', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main bf394ee'), 'rector/rector-downgrade-php' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-downgrade-php', 'relative_install_path' => '../../rector-downgrade-php', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main d441dba'), 'rector/rector-php-parser' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-php-parser', 'relative_install_path' => '../../rector-php-parser', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 9ea5f62'), 'rector/rector-phpunit' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-phpunit', 'relative_install_path' => '../../rector-phpunit', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main e646c56'), 'rector/rector-symfony' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-symfony', 'relative_install_path' => '../../rector-symfony', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main caa1373'));
|
||||
public const EXTENSIONS = array('rector/rector-doctrine' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-doctrine', 'relative_install_path' => '../../rector-doctrine', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main bf394ee'), 'rector/rector-downgrade-php' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-downgrade-php', 'relative_install_path' => '../../rector-downgrade-php', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main d441dba'), 'rector/rector-php-parser' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-php-parser', 'relative_install_path' => '../../rector-php-parser', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 9ea5f62'), 'rector/rector-phpunit' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-phpunit', 'relative_install_path' => '../../rector-phpunit', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main 3d0d84d'), 'rector/rector-symfony' => array('install_path' => '/home/runner/work/rector-src/rector-src/vendor/rector/rector-symfony', 'relative_install_path' => '../../rector-symfony', 'extra' => array('includes' => array(0 => 'config/config.php')), 'version' => 'dev-main caa1373'));
|
||||
private function __construct()
|
||||
{
|
||||
}
|
||||
|
|
|
@ -48,8 +48,8 @@ final class ExpectExceptionMethodCallFactory
|
|||
if (!$phpDocTagNode->value instanceof GenericTagValueNode) {
|
||||
throw new ShouldNotHappenException();
|
||||
}
|
||||
$node = $this->createExpectedExpr($phpDocTagNode, $phpDocTagNode->value);
|
||||
return $this->nodeFactory->createMethodCall('this', $methodName, [new Arg($node)]);
|
||||
$expr = $this->createExpectedExpr($phpDocTagNode, $phpDocTagNode->value);
|
||||
return $this->nodeFactory->createMethodCall('this', $methodName, [new Arg($expr)]);
|
||||
}
|
||||
private function createExpectedExpr(PhpDocTagNode $phpDocTagNode, GenericTagValueNode $genericTagValueNode) : Expr
|
||||
{
|
||||
|
|
|
@ -33,7 +33,10 @@ foreach ($foos as $foo) {
|
|||
$this->assertInstanceOf(SplFileInfo::class, $foo);
|
||||
}
|
||||
CODE_SAMPLE
|
||||
, '$this->assertContainsOnlyInstancesOf(\\SplFileInfo::class, $foos);')]);
|
||||
, <<<'CODE_SAMPLE'
|
||||
$this->assertContainsOnlyInstancesOf(\SplFileInfo::class, $foos);
|
||||
CODE_SAMPLE
|
||||
)]);
|
||||
}
|
||||
/**
|
||||
* @return array<class-string<Node>>
|
||||
|
|
|
@ -43,7 +43,7 @@ final class AssertCompareToSpecificMethodRector extends AbstractRector
|
|||
}
|
||||
public function getRuleDefinition() : RuleDefinition
|
||||
{
|
||||
return new RuleDefinition('Turns vague php-only method in PHPUnit TestCase to more specific', [new CodeSample('$this->assertSame(10, count($anything), "message");', '$this->assertCount(10, $anything, "message");'), new CodeSample('$this->assertNotEquals(get_class($value), stdClass::class);', '$this->assertNotInstanceOf(stdClass::class, $value);')]);
|
||||
return new RuleDefinition('Turns vague php-only method in PHPUnit TestCase to more specific', [new CodeSample('$this->assertSame(10, count($anything), "message");', '$this->assertCount(10, $anything, "message");'), new CodeSample('$this->assertNotEquals(get_class($value), SomeInstance::class);', '$this->assertNotInstanceOf(SomeInstance::class, $value);')]);
|
||||
}
|
||||
/**
|
||||
* @return array<class-string<Node>>
|
||||
|
|
|
@ -40,8 +40,11 @@ final class DelegateExceptionArgumentsRector extends AbstractRector
|
|||
}
|
||||
public function getRuleDefinition() : RuleDefinition
|
||||
{
|
||||
return new RuleDefinition('Takes `setExpectedException()` 2nd and next arguments to own methods in PHPUnit.', [new CodeSample('$this->setExpectedException(Exception::class, "Message", "CODE");', <<<'CODE_SAMPLE'
|
||||
$this->setExpectedException(Exception::class);
|
||||
return new RuleDefinition('Takes `setExpectedException()` 2nd and next arguments to own methods in PHPUnit.', [new CodeSample(<<<'CODE_SAMPLE'
|
||||
$this->setExpectedException(SomeException::class, "Message", "CODE");
|
||||
CODE_SAMPLE
|
||||
, <<<'CODE_SAMPLE'
|
||||
$this->setExpectedException(SomeException::class);
|
||||
$this->expectExceptionMessage('Message');
|
||||
$this->expectExceptionCode('CODE');
|
||||
CODE_SAMPLE
|
||||
|
|
Loading…
Reference in New Issue
Block a user