From 83f429e0256d54df0c0e5c138101eff3d153497e Mon Sep 17 00:00:00 2001 From: 8ctopus Date: Mon, 22 Sep 2025 11:10:25 +0400 Subject: [PATCH] Add support for phpunit 11 --- composer.json | 2 +- tests/AlignFormatterTest.php | 6 +++--- tests/ColorTest.php | 6 +++--- tests/CombinedAlignSprintfFormatterTest.php | 6 +++--- tests/SimpleTest.php | 6 +++--- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/composer.json b/composer.json index 732187b..f01f94a 100644 --- a/composer.json +++ b/composer.json @@ -18,7 +18,7 @@ "ext-mbstring": "*" }, "require-dev": { - "phpunit/phpunit": "^5|^6|^7|^8|^9|^10", + "phpunit/phpunit": "^5|^6|^7|^8|^9|^10|^11", "friendsofphp/php-cs-fixer": "^2|^3" }, "autoload": { diff --git a/tests/AlignFormatterTest.php b/tests/AlignFormatterTest.php index 1f696d7..cbb08bb 100644 --- a/tests/AlignFormatterTest.php +++ b/tests/AlignFormatterTest.php @@ -16,14 +16,14 @@ class AlignFormatterTest extends TestCase * @dataProvider getCases * * @param mixed $data - * @param mixed $expectResult + * @param mixed $expected */ - public function testCorrectBuilding($data, $expectResult) + public function testCorrectBuilding($data, $expected) { $builder = new ArrayToTextTable($data); $builder->applyFormatter(new AlignFormatter(['center' => 'center', 'right' => 'right'])); - $this->assertEquals($expectResult, $builder->render()); + $this->assertEquals($expected, $builder->render()); } public static function getCases() diff --git a/tests/ColorTest.php b/tests/ColorTest.php index d54f743..46882af 100644 --- a/tests/ColorTest.php +++ b/tests/ColorTest.php @@ -17,9 +17,9 @@ class ColorTest extends TestCase * @dataProvider getCases * * @param mixed $data - * @param mixed $expectResult + * @param mixed $expected */ - public function testCorrectBuilding($data, $expectResult) + public function testCorrectBuilding($data, $expected) { $builder = new ArrayToTextTable($data); $builder->applyFormatter(new ColorFormatter([ @@ -28,7 +28,7 @@ public function testCorrectBuilding($data, $expectResult) } ])); - $this->assertEquals($expectResult, $builder->render()); + $this->assertEquals($expected, $builder->render()); } public static function getCases() diff --git a/tests/CombinedAlignSprintfFormatterTest.php b/tests/CombinedAlignSprintfFormatterTest.php index 2454081..c69024f 100644 --- a/tests/CombinedAlignSprintfFormatterTest.php +++ b/tests/CombinedAlignSprintfFormatterTest.php @@ -17,15 +17,15 @@ class CombinedAlignSprintfFormatterTest extends TestCase * @dataProvider getCases * * @param mixed $data - * @param mixed $expectResult + * @param mixed $expected */ - public function testCorrectBuilding($data, $expectResult) + public function testCorrectBuilding($data, $expected) { $builder = new ArrayToTextTable($data); $builder->applyFormatter(new AlignFormatter(['center' => 'center', 'right' => 'right'])); $builder->applyFormatter(new SprintfFormatter(['right' => '%01.3f'])); - $this->assertEquals($expectResult, $builder->render()); + $this->assertEquals($expected, $builder->render()); } public static function getCases() diff --git a/tests/SimpleTest.php b/tests/SimpleTest.php index 8e0c535..b60cb3d 100644 --- a/tests/SimpleTest.php +++ b/tests/SimpleTest.php @@ -15,13 +15,13 @@ class SimpleTest extends TestCase * @dataProvider getCases * * @param mixed $data - * @param mixed $expectResult + * @param mixed $expected */ - public function testCorrectBuilding($data, $expectResult) + public function testCorrectBuilding($data, $expected) { $builder = new ArrayToTextTable($data); - $this->assertEquals($expectResult, $builder->render()); + $this->assertEquals($expected, $builder->render()); } public static function getCases()