From d0bd783fe11447fa0607a74b0663f29048bf2a63 Mon Sep 17 00:00:00 2001 From: "Eloy Lafuente (stronk7)" Date: Fri, 14 Jun 2024 18:53:02 +0200 Subject: [PATCH] Bump various dependencies - moodle-cs 3.4.8 --- composer.json | 2 +- composer.lock | 65 ++++++++++++------------ docs/CHANGELOG.md | 3 ++ tests/Command/CodeCheckerCommandTest.php | 4 +- tests/Command/CodeFixerCommandTest.php | 16 +++++- 5 files changed, 54 insertions(+), 36 deletions(-) diff --git a/composer.json b/composer.json index 65f784f0..dd131f3c 100755 --- a/composer.json +++ b/composer.json @@ -55,7 +55,7 @@ ], "require": { "php": ">=7.4", - "moodlehq/moodle-cs": "^3.4.7", + "moodlehq/moodle-cs": "^3.4.8", "moodlehq/moodle-local_ci": "^1.0.30", "moodlehq/moodle-local_moodlecheck": "^1.3.2", "sebastian/phpcpd": "^6.0.3", diff --git a/composer.lock b/composer.lock index 5eac720e..491e45ad 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "f52adb63cf7a9dfcfb8c290dfbdd2d98", + "content-hash": "8f35f81ef4f20b7c73e13a14757f70ca", "packages": [ { "name": "composer/pcre", @@ -340,16 +340,16 @@ }, { "name": "moodlehq/moodle-cs", - "version": "v3.4.7", + "version": "v3.4.8", "source": { "type": "git", "url": "https://github.com/moodlehq/moodle-cs.git", - "reference": "4f1bc63551da69675d9f5d17efbf35a458ca3da8" + "reference": "91661a17a23ed17e7ae4276f8c19df789b8882c2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/moodlehq/moodle-cs/zipball/4f1bc63551da69675d9f5d17efbf35a458ca3da8", - "reference": "4f1bc63551da69675d9f5d17efbf35a458ca3da8", + "url": "https://api.github.com/repos/moodlehq/moodle-cs/zipball/91661a17a23ed17e7ae4276f8c19df789b8882c2", + "reference": "91661a17a23ed17e7ae4276f8c19df789b8882c2", "shasum": "" }, "require": { @@ -406,7 +406,7 @@ "source": "https://github.com/moodlehq/moodle-cs", "wiki": "https://github.com/moodlehq/moodle-cs/wiki" }, - "time": "2024-05-31T16:28:39+00:00" + "time": "2024-06-14T14:47:25+00:00" }, { "name": "moodlehq/moodle-local_ci", @@ -803,8 +803,8 @@ }, "require": { "php": ">=5.4", - "phpcsstandards/phpcsutils": "^1.0.9", - "squizlabs/php_codesniffer": "^3.9.0" + "phpcsstandards/phpcsutils": "^1.0.12", + "squizlabs/php_codesniffer": "^3.10.0" }, "replace": { "wimg/php-compatibility": "*" @@ -875,7 +875,7 @@ "type": "open_collective" } ], - "time": "2024-04-30T23:24:59+00:00" + "time": "2024-06-07T09:46:11+00:00" }, { "name": "phpcsstandards/phpcsextra", @@ -3891,16 +3891,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.11.1", + "version": "1.12.0", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c" + "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", - "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", + "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", "shasum": "" }, "require": { @@ -3908,11 +3908,12 @@ }, "conflict": { "doctrine/collections": "<1.6.8", - "doctrine/common": "<2.13.3 || >=3,<3.2.2" + "doctrine/common": "<2.13.3 || >=3 <3.2.2" }, "require-dev": { "doctrine/collections": "^1.6.8", "doctrine/common": "^2.13.3 || ^3.2.2", + "phpspec/prophecy": "^1.10", "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" }, "type": "library", @@ -3938,7 +3939,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.11.1" + "source": "https://github.com/myclabs/DeepCopy/tree/1.12.0" }, "funding": [ { @@ -3946,7 +3947,7 @@ "type": "tidelift" } ], - "time": "2023-03-08T13:26:56+00:00" + "time": "2024-06-12T14:39:25+00:00" }, { "name": "netresearch/jsonmapper", @@ -4845,28 +4846,28 @@ }, { "name": "react/dns", - "version": "v1.12.0", + "version": "v1.13.0", "source": { "type": "git", "url": "https://github.com/reactphp/dns.git", - "reference": "c134600642fa615b46b41237ef243daa65bb64ec" + "reference": "eb8ae001b5a455665c89c1df97f6fb682f8fb0f5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/reactphp/dns/zipball/c134600642fa615b46b41237ef243daa65bb64ec", - "reference": "c134600642fa615b46b41237ef243daa65bb64ec", + "url": "https://api.github.com/repos/reactphp/dns/zipball/eb8ae001b5a455665c89c1df97f6fb682f8fb0f5", + "reference": "eb8ae001b5a455665c89c1df97f6fb682f8fb0f5", "shasum": "" }, "require": { "php": ">=5.3.0", "react/cache": "^1.0 || ^0.6 || ^0.5", "react/event-loop": "^1.2", - "react/promise": "^3.0 || ^2.7 || ^1.2.1" + "react/promise": "^3.2 || ^2.7 || ^1.2.1" }, "require-dev": { "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36", - "react/async": "^4 || ^3 || ^2", - "react/promise-timer": "^1.9" + "react/async": "^4.3 || ^3 || ^2", + "react/promise-timer": "^1.11" }, "type": "library", "autoload": { @@ -4909,7 +4910,7 @@ ], "support": { "issues": "https://github.com/reactphp/dns/issues", - "source": "https://github.com/reactphp/dns/tree/v1.12.0" + "source": "https://github.com/reactphp/dns/tree/v1.13.0" }, "funding": [ { @@ -4917,7 +4918,7 @@ "type": "open_collective" } ], - "time": "2023-11-29T12:41:06+00:00" + "time": "2024-06-13T14:18:03+00:00" }, { "name": "react/event-loop", @@ -5146,16 +5147,16 @@ }, { "name": "react/stream", - "version": "v1.3.0", + "version": "v1.4.0", "source": { "type": "git", "url": "https://github.com/reactphp/stream.git", - "reference": "6fbc9672905c7d5a885f2da2fc696f65840f4a66" + "reference": "1e5b0acb8fe55143b5b426817155190eb6f5b18d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/reactphp/stream/zipball/6fbc9672905c7d5a885f2da2fc696f65840f4a66", - "reference": "6fbc9672905c7d5a885f2da2fc696f65840f4a66", + "url": "https://api.github.com/repos/reactphp/stream/zipball/1e5b0acb8fe55143b5b426817155190eb6f5b18d", + "reference": "1e5b0acb8fe55143b5b426817155190eb6f5b18d", "shasum": "" }, "require": { @@ -5165,7 +5166,7 @@ }, "require-dev": { "clue/stream-filter": "~1.2", - "phpunit/phpunit": "^9.5 || ^5.7 || ^4.8.35" + "phpunit/phpunit": "^9.6 || ^5.7 || ^4.8.36" }, "type": "library", "autoload": { @@ -5212,7 +5213,7 @@ ], "support": { "issues": "https://github.com/reactphp/stream/issues", - "source": "https://github.com/reactphp/stream/tree/v1.3.0" + "source": "https://github.com/reactphp/stream/tree/v1.4.0" }, "funding": [ { @@ -5220,7 +5221,7 @@ "type": "open_collective" } ], - "time": "2023-06-16T10:52:11+00:00" + "time": "2024-06-11T12:45:25+00:00" }, { "name": "sebastian/code-unit", diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 9c96b566..afb3c66d 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,6 +9,9 @@ This project adheres to [Semantic Versioning](http://semver.org/). The format of this change log follows the advice given at [Keep a CHANGELOG](http://keepachangelog.com). ## [Unreleased] +### Changed +- Updated project dependencies to current [moodle-cs v3.4.8](https://github.com/moodlehq/moodle-cs) release. + ### Fixed - Fixed a problem with the `grunt` command running the `stylelint` tasks against the whole Moodle directory (including both core and other optional plugins installed). Now only the plugin being checked is effectively analysed. diff --git a/tests/Command/CodeCheckerCommandTest.php b/tests/Command/CodeCheckerCommandTest.php index 3cb4a0d0..54f98942 100644 --- a/tests/Command/CodeCheckerCommandTest.php +++ b/tests/Command/CodeCheckerCommandTest.php @@ -97,7 +97,7 @@ abstract private function somefunc() { // To verify PHPCompatibility sniff. $this->assertMatchesRegularExpression('/E\.* 10\.* \/ 10 \(100%\)/', $output); // Progress. $this->assertMatchesRegularExpression('/\/fixable.php/', $output); // File. $this->assertMatchesRegularExpression('/ 11 ERRORS AND 1 WARNING AFFECTING 8 /', $output); // Summary. - $this->assertMatchesRegularExpression('/moodle\.Files\.BoilerplateComment\.Wrong/', $output); // Moodle sniff. + $this->assertMatchesRegularExpression('/BoilerplateComment\.NoBoilerplateComment/', $output); // Moodle sniff. $this->assertMatchesRegularExpression('/Expected MOODLE_INTERNAL check/', $output); // Moodle sniff. $this->assertMatchesRegularExpression('/print_error\(\) has been deprecated/', $output); // Moodle sniff. $this->assertMatchesRegularExpression('/Usage of ELSEIF not allowed; use ELSE IF/', $output); // Squiz sniff. @@ -109,7 +109,7 @@ abstract private function somefunc() { // To verify PHPCompatibility sniff. $this->assertMatchesRegularExpression('/AbstractPrivateMethods\.Found/', $output); // PHPCompatibility sniff. $this->assertMatchesRegularExpression('/Opening brace must be the last content/', $output); // Generic sniff. $this->assertMatchesRegularExpression('/Files\.EndFileNewline\.NotFound/', $output); // Generic of file. - $this->assertMatchesRegularExpression('/PHPCBF CAN FIX THE 3 MARKED SNIFF/', $output); // PHPCBF note. + $this->assertMatchesRegularExpression('/PHPCBF CAN FIX THE 4 MARKED SNIFF/', $output); // PHPCBF note. $this->assertMatchesRegularExpression('/Time:.*Memory:/', $output); // Time. // Also verify display info is correct. diff --git a/tests/Command/CodeFixerCommandTest.php b/tests/Command/CodeFixerCommandTest.php index 33231096..f6cad124 100644 --- a/tests/Command/CodeFixerCommandTest.php +++ b/tests/Command/CodeFixerCommandTest.php @@ -78,7 +78,7 @@ public function testExecute() $output = $commandTester->getDisplay(); $this->assertMatchesRegularExpression('/F\.* 10\.* \/ 10 \(100%\)/', $output); // Progress. $this->assertMatchesRegularExpression('/\/fixable.php/', $output); // File. - $this->assertMatchesRegularExpression('/A TOTAL OF 1 ERROR WERE FIXED IN 1 FILE/', $output); // Summary. + $this->assertMatchesRegularExpression('/A TOTAL OF 2 ERRORS WERE FIXED IN 1 FILE/', $output); // Summary. $this->assertMatchesRegularExpression('/Time:.*Memory:/', $output); // Time. // Also verify display info is correct. @@ -86,6 +86,20 @@ public function testExecute() $expected = <<<'EOT' . if (true) {