Skip to content

Commit

Permalink
bump tooling version
Browse files Browse the repository at this point in the history
  • Loading branch information
tbali0524 committed Jun 24, 2024
1 parent bbd0cbe commit 44891e0
Show file tree
Hide file tree
Showing 17 changed files with 24 additions and 20 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/qa.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
uses: shivammathur/setup-php@v2
with:
php-version: "8.3"
tools: phpcs:3.9, php-cs-fixer:3.56, phpstan:1.11
tools: phpcs:3.10, php-cs-fixer:3.59, phpstan:1.11
coverage: none
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -45,7 +45,7 @@ jobs:
with:
php-version: "8.3"
extensions: mbstring, bcmath, xdebug
tools: phpunit:11.1
tools: phpunit:11.2
coverage: xdebug
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
3 changes: 2 additions & 1 deletion .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* php-cs-fixer configuration file.
*
* minimum version: ^3.56
* minimum version: ^3.59
*
* @see https://cs.symfony.com/doc/config.html
*/
Expand Down Expand Up @@ -55,5 +55,6 @@
->setCacheFile(__DIR__ . '/.tools/.php-cs-fixer.cache')
->setIndent(" ")
->setLineEnding("\n")
->setParallelConfig(PhpCsFixer\Runner\Parallel\ParallelConfigFactory::detect())
->setFinder($finder)
;
2 changes: 2 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@
"metrics": "phpmetrics --config=.phpmetrics.json",
"stan": "phpstan --ansi --verbose",
"qa": [
"parallel-lint --version",
"@lint",
"phpcs --version",
"@cs",
"@cs-fixer",
Expand Down
3 changes: 2 additions & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion phpcs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!--
phpcs configuration file.
minimum version: ^3.9
minimum version: ^3.10
@see https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Annotated-Ruleset
-->
Expand Down
2 changes: 1 addition & 1 deletion phpdoc.dist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!--
PHPDocumentor configuration file.
minimum version: ^3.2
minimum version: ^3.5
@see https://docs.phpdoc.org/guide/references/configuration.html
-->
Expand Down
4 changes: 2 additions & 2 deletions phpunit.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
<!--
PHPUnit configuration file.
minimum version: ^11.1
minimum version: ^11.2
@see https://phpunit.readthedocs.io/en/11.0/configuration.html
-->
<phpunit
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/11.1/phpunit.xsd"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/11.2/phpunit.xsd"
bootstrap="vendor/autoload.php"
cacheDirectory=".tools/.phpunit.cache/"
colors="true"
Expand Down
4 changes: 2 additions & 2 deletions src/Aoc/AocRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ public function run(): void
echo '======= ' . $year . ' ' . str_repeat('=', 45) . PHP_EOL;
$lastYear = $year;
}
if (isset(self::TO_SKIP[$year]) and in_array($day, self::TO_SKIP[$year])) {
if (in_array($day, self::TO_SKIP[$year])) {
echo '=== AoC ' . $year . ' Day ' . str_pad(strval($day), 2, '0', STR_PAD_LEFT) . PHP_EOL;
echo Tags::WARN_TAG . 'Skipped.' . PHP_EOL;
++$countSkipped;
Expand Down Expand Up @@ -189,7 +189,7 @@ public function runSingleAsClass(int $year, int $day): bool
return false;
}
$className = $this->getClassName($year, $day);
$fullClassName = 'TBali\\Aoc' . $year . '\\' . $className;
$fullClassName = 'TBali\Aoc' . $year . '\\' . $className;
/** @var Solution */
$solution = new $fullClassName();
$success = $solution->run();
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2015Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2015Day01::class)]
#[CoversClass(Aoc2015Day02::class)]
#[CoversClass(Aoc2015Day03::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2016Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2016Day01::class)]
#[CoversClass(Aoc2016Day02::class)]
#[CoversClass(Aoc2016Day03::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2017Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2017Day01::class)]
#[CoversClass(Aoc2017Day02::class)]
#[CoversClass(Aoc2017Day03::class)]
Expand Down
4 changes: 2 additions & 2 deletions tests/Aoc2018Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2018Day01::class)]
#[CoversClass(Aoc2018Day02::class)]
#[CoversClass(Aoc2018Day03::class)]
Expand Down Expand Up @@ -520,7 +520,7 @@ public function testDay13(): void
public function testDay13InvalidInput1(): void
{
$solver = new Aoc2018Day13();
$input = ['/-\\', '\\-/'];
$input = ['/-\\', '\-/'];
$this->expectException(\Exception::class);
[$ans1, $ans2] = $solver->solve($input);
}
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2019Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2019Day01::class)]
#[CoversClass(Aoc2019Day02::class)]
#[CoversClass(Aoc2019Day03::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2020Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2020Day01::class)]
#[CoversClass(Aoc2020Day02::class)]
#[CoversClass(Aoc2020Day03::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2021Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2021Day01::class)]
#[CoversClass(Aoc2021Day02::class)]
#[CoversClass(Aoc2021Day03::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2022Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2022Day01::class)]
#[CoversClass(Aoc2022Day02::class)]
#[CoversClass(Aoc2022Day03::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/Aoc2023Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
* @coversNothing
*/
#[RequiresPhp('^8.3')]
#[RequiresPhpunit('^11.0')]
#[RequiresPhpunit('^11.2')]
#[CoversClass(Aoc2023Day01::class)]
#[CoversClass(Aoc2023Day02::class)]
#[CoversClass(Aoc2023Day03::class)]
Expand Down

0 comments on commit 44891e0

Please sign in to comment.