Updated Rector to commit 06cb6754d6f04703093905fbaddbbbe4f9546a22

06cb6754d6 move package ci status directly to README to make easier to discovery
This commit is contained in:
Tomas Votruba 2022-12-03 10:51:45 +00:00
parent afd435c4e5
commit d2a6e3f136
11 changed files with 33 additions and 27 deletions

View File

@ -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
View File

@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) {
require_once __DIR__ . '/composer/autoload_real.php';
return ComposerAutoloaderInit450137aec28b4099823df530616baf1c::getLoader();
return ComposerAutoloaderInit5424342770688078c8dad80f32ef58ea::getLoader();

View File

@ -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;

View File

@ -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);
}

View File

@ -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"
},

File diff suppressed because one or more lines are too long

View File

@ -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()
{
}

View File

@ -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
{

View File

@ -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>>

View File

@ -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>>

View File

@ -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