Jgleeson has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/399670 )

Change subject: Restored `composer test` script
......................................................................

Restored `composer test` script

Fix 1) supply current path as argument to parallel-lint
Fix 2) remove deprecated code from civi package
Fix 3) added support to jsonlint for multiple JSON file arguments

Notes:

--Deprecated stuff--
Parallel-lint is failing in php7 due to usage of the deprecated
'= &new' being used (deprecated in 5.3) in code within the civi
submodule. Oddly this does not fail on vagrant which is running 5.6
This is removed here https://gerrit.wikimedia.org/r/#/c/399669/

--JSON files--
I have excluded all *vendor* and *bower* directories from the scan
for project JSON files to lint.

--Temporary jsonlint--
I have forked and updated seld/jsonlint so we can support multiple
file arguments in `jsonlint`. As a result of this, I have swapped
out the composer dependency over to jackgleeson/jsonlint until the
update is approved and merged into the upstream.

jsonlint PR link here: https://github.com/Seldaek/jsonlint/pull/48

Change-Id: I15839394a522cc0f11a3bd8300aaf67dfdd795dd
---
M composer.json
M composer.lock
2 files changed, 52 insertions(+), 54 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/70/399670/1

diff --git a/composer.json b/composer.json
index 81456c6..fc776d8 100644
--- a/composer.json
+++ b/composer.json
@@ -40,11 +40,15 @@
       {
         "type": "git",
         "url": "https://github.com/eileenmcnaughton/silverpop-php-connector";
+      },
+      {
+        "type": "git",
+        "url": "https://github.com/jackgleeson/jsonlint";
       }
     ],
     "require-dev": {
         "phpunit/phpunit": "5.*",
-        "seld/jsonlint": "~1.6.0",
+        "jackgleeson/jsonlint": "dev-master",
         "jakub-onderka/php-parallel-lint": "~0.9.2",
         "jakub-onderka/php-console-highlighter": "~0.3.2",
         "wikimedia/testing-access-wrapper": "~1.0"
@@ -54,8 +58,8 @@
     },
     "scripts": {
       "test": [
-        "parallel-lint -e php,module,install,inc --exclude vendor --exclude 
sites/default/civicrm/extensions/org.wikimedia.omnimail/vendor.",
-        "php bin/jsonlint.php"
+        "parallel-lint -e php,module,install,inc --exclude vendor --exclude 
sites/default/civicrm/extensions/org.wikimedia.omnimail/vendor .",
+        "jsonlint $(find . -type f -iname \"*.json\" ! -path \"*/vendor/*\" ! 
-path \"*/bower*\" -printf \"%p \")"
       ]
     },
     "minimum-stability": "dev",
diff --git a/composer.lock b/composer.lock
index 2ae68da..0dde166 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
         "Read more about it at 
https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file";,
         "This file is @generated automatically"
     ],
-    "content-hash": "f5b1e547c9865d17802925641c804265",
+    "content-hash": "a0c4c1469e3cfbd7c6bcab761a34ffc4",
     "packages": [
         {
             "name": "addshore/psr-6-mediawiki-bagostuff-adapter",
@@ -88,7 +88,7 @@
                 "payment",
                 "payments"
             ],
-            "time": "2016-02-17T00:44:20+00:00"
+            "time": "2016-02-17T00:53:20+00:00"
         },
         {
             "name": "clio/clio",
@@ -2402,6 +2402,48 @@
             "time": "2015-06-14T21:17:01+00:00"
         },
         {
+            "name": "jackgleeson/jsonlint",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/jackgleeson/jsonlint";,
+                "reference": "f37d7863cdc52e9794ec829b817a9370354a4396"
+            },
+            "require": {
+                "php": "^5.3 || ^7.0"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0"
+            },
+            "bin": [
+                "bin/jsonlint"
+            ],
+            "type": "library",
+            "autoload": {
+                "psr-4": {
+                    "Seld\\JsonLint\\": "src/Seld/JsonLint/"
+                }
+            },
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Jordi Boggiano",
+                    "email": "[email protected]",
+                    "homepage": "http://seld.be";
+                }
+            ],
+            "description": "JSON Linter",
+            "keywords": [
+                "json",
+                "linter",
+                "parser",
+                "validator"
+            ],
+            "time": "2017-12-21T17:29:04+00:00"
+        },
+        {
             "name": "jakub-onderka/php-console-color",
             "version": "0.1",
             "source": {
@@ -3730,55 +3772,6 @@
             "time": "2016-10-03T07:35:21+00:00"
         },
         {
-            "name": "seld/jsonlint",
-            "version": "1.6.1",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/Seldaek/jsonlint.git";,
-                "reference": "50d63f2858d87c4738d5b76a7dcbb99fa8cf7c77"
-            },
-            "dist": {
-                "type": "zip",
-                "url": 
"https://api.github.com/repos/Seldaek/jsonlint/zipball/50d63f2858d87c4738d5b76a7dcbb99fa8cf7c77";,
-                "reference": "50d63f2858d87c4738d5b76a7dcbb99fa8cf7c77",
-                "shasum": ""
-            },
-            "require": {
-                "php": "^5.3 || ^7.0"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "^4.5"
-            },
-            "bin": [
-                "bin/jsonlint"
-            ],
-            "type": "library",
-            "autoload": {
-                "psr-4": {
-                    "Seld\\JsonLint\\": "src/Seld/JsonLint/"
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/";,
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Jordi Boggiano",
-                    "email": "[email protected]",
-                    "homepage": "http://seld.be";
-                }
-            ],
-            "description": "JSON Linter",
-            "keywords": [
-                "json",
-                "linter",
-                "parser",
-                "validator"
-            ],
-            "time": "2017-06-18T15:11:04+00:00"
-        },
-        {
             "name": "webmozart/assert",
             "version": "1.2.0",
             "source": {
@@ -3885,6 +3878,7 @@
         "amzn/login-and-pay-with-amazon-sdk-php": 20,
         "wikimedia/donation-interface": 20,
         "jackgleeson/stats-collector": 20,
+        "jackgleeson/jsonlint": 20,
         "wikimedia/omnimail-silverpop": 20,
         "mrmarkfrench/silverpop-php-connector": 20,
         "omnimail/omnimail": 20

-- 
To view, visit https://gerrit.wikimedia.org/r/399670
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I15839394a522cc0f11a3bd8300aaf67dfdd795dd
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Jgleeson <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to