From c1e06d9df22adaf1f0ae646dfbc0620b28e9a79a Mon Sep 17 00:00:00 2001 From: Krzysztof Rewak Date: Tue, 4 Jan 2022 08:21:36 +0100 Subject: [PATCH] #45 - references in method signatures (#46) --- composer.json | 2 +- tests/codestyle/CodestyleTest.php | 2 ++ tests/codestyle/fixtures/readonlies/actual.php | 10 ++++++++++ tests/codestyle/fixtures/readonlies/expected.php | 13 +++++++++++++ tests/codestyle/fixtures/references/actual.php | 8 ++++++++ tests/codestyle/fixtures/references/expected.php | 10 ++++++++++ 6 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 tests/codestyle/fixtures/readonlies/actual.php create mode 100644 tests/codestyle/fixtures/readonlies/expected.php create mode 100644 tests/codestyle/fixtures/references/actual.php create mode 100644 tests/codestyle/fixtures/references/expected.php diff --git a/composer.json b/composer.json index 95d387f..cc1707b 100644 --- a/composer.json +++ b/composer.json @@ -5,7 +5,7 @@ "type": "library", "require": { "php": "^8.0", - "symplify/easy-coding-standard": "10.0.2" + "symplify/easy-coding-standard": "10.0.8" }, "require-dev": { "composer/composer": "2.*", diff --git a/tests/codestyle/CodestyleTest.php b/tests/codestyle/CodestyleTest.php index ac316c9..b99e264 100644 --- a/tests/codestyle/CodestyleTest.php +++ b/tests/codestyle/CodestyleTest.php @@ -31,6 +31,7 @@ public function testPhp80Fixtures(): void "strictTypes", "trailingCommas", "unionTypes", + "references", ]; foreach ($fixtures as $fixture) { @@ -46,6 +47,7 @@ public function testPhp81Fixtures(): void { $fixtures = [ "enums", + "readonlies", ]; foreach ($fixtures as $fixture) { diff --git a/tests/codestyle/fixtures/readonlies/actual.php b/tests/codestyle/fixtures/readonlies/actual.php new file mode 100644 index 0000000..da597ec --- /dev/null +++ b/tests/codestyle/fixtures/readonlies/actual.php @@ -0,0 +1,10 @@ +