Skip to content

Commit

Permalink
Merge pull request #8384 from kenjis/update-cs-fixer-v3.43.0
Browse files Browse the repository at this point in the history
style: update coding style by php-cs-fixer v3.43.0
  • Loading branch information
kenjis authored Dec 29, 2023
2 parents 95d4a8b + f514d3b commit e424098
Show file tree
Hide file tree
Showing 7 changed files with 51 additions and 26 deletions.
25 changes: 25 additions & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,31 @@
'use',
],
],
'fully_qualified_strict_types' => [
'import_symbols' => false,
'leading_backslash_in_global_namespace' => false,
'phpdoc_tags' => [
'param',
'phpstan-param',
'phpstan-property',
'phpstan-property-read',
'phpstan-property-write',
'phpstan-return',
'phpstan-var',
'property',
'property-read',
'property-write',
'psalm-param',
'psalm-property',
'psalm-property-read',
'psalm-property-write',
'psalm-return',
'psalm-var',
'return',
'throws',
'var',
],
],
];

$options = [
Expand Down
2 changes: 1 addition & 1 deletion admin/framework/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"require-dev": {
"codeigniter/coding-standard": "^1.5",
"fakerphp/faker": "^1.9",
"friendsofphp/php-cs-fixer": "~3.41.0",
"friendsofphp/php-cs-fixer": "^3.43",
"kint-php/kint": "^5.0.4",
"mikey179/vfsstream": "^1.6",
"nexusphp/cs-config": "^3.6",
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"codeigniter/phpstan-codeigniter": "^1.4",
"ergebnis/composer-normalize": "^2.28",
"fakerphp/faker": "^1.9",
"friendsofphp/php-cs-fixer": "~3.41.0",
"friendsofphp/php-cs-fixer": "^3.43",
"kint-php/kint": "^5.0.4",
"mikey179/vfsstream": "^1.6",
"nexusphp/cs-config": "^3.6",
Expand Down
32 changes: 16 additions & 16 deletions system/Debug/Toolbar/Views/toolbar.tpl.php
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
<?php
/**
* @var \CodeIgniter\Debug\Toolbar $this
* @var int $totalTime
* @var int $totalMemory
* @var string $url
* @var string $method
* @var bool $isAJAX
* @var int $startTime
* @var int $totalTime
* @var int $totalMemory
* @var float $segmentDuration
* @var int $segmentCount
* @var string $CI_VERSION
* @var array $collectors
* @var array $vars
* @var array $styles
* @var \CodeIgniter\View\Parser $parser
* @var CodeIgniter\Debug\Toolbar $this
* @var int $totalTime
* @var int $totalMemory
* @var string $url
* @var string $method
* @var bool $isAJAX
* @var int $startTime
* @var int $totalTime
* @var int $totalMemory
* @var float $segmentDuration
* @var int $segmentCount
* @var string $CI_VERSION
* @var array $collectors
* @var array $vars
* @var array $styles
* @var CodeIgniter\View\Parser $parser
*/
?>
<style>
Expand Down
2 changes: 1 addition & 1 deletion system/Exceptions/FrameworkException.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public static function forMissingExtension(string $extension)
'The framework needs the following extension(s) installed and loaded: %s.',
$extension
);
// @codeCoverageIgnoreEnd
// @codeCoverageIgnoreEnd
} else {
$message = lang('Core.missingExtension', [$extension]);
}
Expand Down
12 changes: 6 additions & 6 deletions tests/system/Router/AutoRouterImprovedTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ public function testAutoRouteFindsControllerWithSubfolder(): void
= $router->getRoute('subfolder/mycontroller/somemethod', 'get');

$this->assertSame('Subfolder/', $directory);
$this->assertSame('\\' . \CodeIgniter\Router\Controllers\Subfolder\Mycontroller::class, $controller);
$this->assertSame('\\' . Controllers\Subfolder\Mycontroller::class, $controller);
$this->assertSame('getSomemethod', $method);
$this->assertSame([], $params);
$this->assertSame([
Expand All @@ -195,7 +195,7 @@ public function testAutoRouteFindsControllerWithSubSubfolder()
= $router->getRoute('subfolder/sub/mycontroller/somemethod', 'get');

$this->assertSame('Subfolder/Sub/', $directory);
$this->assertSame('\\' . \CodeIgniter\Router\Controllers\Subfolder\Sub\Mycontroller::class, $controller);
$this->assertSame('\\' . Controllers\Subfolder\Sub\Mycontroller::class, $controller);
$this->assertSame('getSomemethod', $method);
$this->assertSame([], $params);
}
Expand All @@ -209,7 +209,7 @@ public function testAutoRouteFindsDashedSubfolder(): void

$this->assertSame('Dash_folder/', $directory);
$this->assertSame(
'\\' . \CodeIgniter\Router\Controllers\Dash_folder\Mycontroller::class,
'\\' . Controllers\Dash_folder\Mycontroller::class,
$controller
);
$this->assertSame('getSomemethod', $method);
Expand Down Expand Up @@ -281,7 +281,7 @@ public function testAutoRouteFallbackToDefaultControllerOneParam()
= $router->getRoute('subfolder/15', 'get');

$this->assertSame('Subfolder/', $directory);
$this->assertSame('\\' . \CodeIgniter\Router\Controllers\Subfolder\Home::class, $controller);
$this->assertSame('\\' . Controllers\Subfolder\Home::class, $controller);
$this->assertSame('getIndex', $method);
$this->assertSame(['15'], $params);
$this->assertSame([
Expand All @@ -299,7 +299,7 @@ public function testAutoRouteFallbackToDefaultControllerTwoParams()
= $router->getRoute('subfolder/15/20', 'get');

$this->assertSame('Subfolder/', $directory);
$this->assertSame('\\' . \CodeIgniter\Router\Controllers\Subfolder\Home::class, $controller);
$this->assertSame('\\' . Controllers\Subfolder\Home::class, $controller);
$this->assertSame('getIndex', $method);
$this->assertSame(['15', '20'], $params);
$this->assertSame([
Expand All @@ -317,7 +317,7 @@ public function testAutoRouteFallbackToDefaultControllerNoParams()
= $router->getRoute('subfolder', 'get');

$this->assertSame('Subfolder/', $directory);
$this->assertSame('\\' . \CodeIgniter\Router\Controllers\Subfolder\Home::class, $controller);
$this->assertSame('\\' . Controllers\Subfolder\Home::class, $controller);
$this->assertSame('getIndex', $method);
$this->assertSame([], $params);
$this->assertSame([
Expand Down
2 changes: 1 addition & 1 deletion user_guide_src/source/models/entities/018.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class MyEntity extends Entity

// Bind the type to the handler
protected $castHandlers = [
'base64' => \App\Entities\Cast\CastBase64::class,
'base64' => Cast\CastBase64::class,
];
}

Expand Down

0 comments on commit e424098

Please sign in to comment.