diff --git a/.github/workflows/acms.yml b/.github/workflows/acms.yml index f7f2a252..91d6cafd 100644 --- a/.github/workflows/acms.yml +++ b/.github/workflows/acms.yml @@ -14,7 +14,7 @@ on: env: ORCA_SUT_NAME: acquia/acquia-cms-starterkit ORCA_SUT_BRANCH: develop - ORCA_VERSION: ^3 + ORCA_VERSION: ^4 ORCA_PACKAGES_CONFIG_ALTER: ../acquia-cms-starterkit/tests/packages_alter.yml ORCA_ENABLE_NIGHTWATCH: "FALSE" DB_DATABASE: drupal @@ -33,7 +33,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@v2 with: - php-version: 8.1 + php-version: 8.3 coverage: xdebug - name: Download ORCA run: composer create-project --no-dev --ignore-platform-req=php acquia/orca ../orca "$ORCA_VERSION" -n @@ -97,7 +97,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@v2 with: - php-version: 8.1 + php-version: 8.3 coverage: xdebug - name: Set up MySQL run: | @@ -162,7 +162,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@v2 with: - php-version: 8.1 + php-version: 8.3 coverage: xdebug - name: Setup NextJs Application run: | @@ -223,7 +223,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@v2 with: - php-version: 8.1 + php-version: 8.3 coverage: xdebug - name: Set up MySQL run: | diff --git a/README.md b/README.md index 6d06eb34..518cd1d9 100644 --- a/README.md +++ b/README.md @@ -25,3 +25,7 @@ Run the following command to to set up site: ``` ./vendor/bin/acms acms:install ``` + +###### Note: Starter kit enable modules in bulk during installation which required minimum PHP memory limit to be 256M. + +Check memory_limit using command `php -i | grep "memory_limit"`,If php memory limit is less than 256 then locate php.ini file and update memory_limit to 256 diff --git a/composer.json b/composer.json index 0eb3b264..776f59f2 100644 --- a/composer.json +++ b/composer.json @@ -25,7 +25,7 @@ "require": { "acquia/drupal-environment-detector": "^1.6", "composer/composer": "^2.7.0", - "stecman/symfony-console-completion": "^0.11.0 || ^0.12.1", + "stecman/symfony-console-completion": "^0.12.1 || ^0.13.0", "symfony/config": "^6.2 || ^7.0", "symfony/console": "^6.2 || ^7.0", "symfony/dependency-injection": "^6.2 || ^7.0", diff --git a/composer.lock b/composer.lock index e0946950..63e3f138 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": "8de48cf27d3297e33fe94df89f4e28d6", + "content-hash": "c4b5f93eeaf5487ea33c582ec7b128ac", "packages": [ { "name": "acquia/drupal-environment-detector", @@ -694,12 +694,12 @@ "version": "v5.2.13", "source": { "type": "git", - "url": "https://github.com/justinrainbow/json-schema.git", + "url": "https://github.com/jsonrainbow/json-schema.git", "reference": "fbbe7e5d79f618997bc3332a6f49246036c45793" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/justinrainbow/json-schema/zipball/fbbe7e5d79f618997bc3332a6f49246036c45793", + "url": "https://api.github.com/repos/jsonrainbow/json-schema/zipball/fbbe7e5d79f618997bc3332a6f49246036c45793", "reference": "fbbe7e5d79f618997bc3332a6f49246036c45793", "shasum": "" }, @@ -754,8 +754,8 @@ "schema" ], "support": { - "issues": "https://github.com/justinrainbow/json-schema/issues", - "source": "https://github.com/justinrainbow/json-schema/tree/v5.2.13" + "issues": "https://github.com/jsonrainbow/json-schema/issues", + "source": "https://github.com/jsonrainbow/json-schema/tree/v5.2.13" }, "time": "2023-09-26T02:20:38+00:00" }, @@ -1160,21 +1160,21 @@ }, { "name": "stecman/symfony-console-completion", - "version": "v0.12.2", + "version": "v0.13.0", "source": { "type": "git", "url": "https://github.com/stecman/symfony-console-completion.git", - "reference": "17e105a12ad8ce0ae1347e6ef5d2cf4c96b8fd1b" + "reference": "769e6b49123847648ae80f10d3ccb0f128cbb953" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/stecman/symfony-console-completion/zipball/17e105a12ad8ce0ae1347e6ef5d2cf4c96b8fd1b", - "reference": "17e105a12ad8ce0ae1347e6ef5d2cf4c96b8fd1b", + "url": "https://api.github.com/repos/stecman/symfony-console-completion/zipball/769e6b49123847648ae80f10d3ccb0f128cbb953", + "reference": "769e6b49123847648ae80f10d3ccb0f128cbb953", "shasum": "" }, "require": { "php": ">=8.0.2", - "symfony/console": "~6.3" + "symfony/console": "~6.3 || ^7.0" }, "require-dev": { "dms/phpunit-arraysubset-asserts": "^0.4.0", @@ -1183,7 +1183,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "0.12.x-dev" + "dev-master": "0.14.x-dev" } }, "autoload": { @@ -1204,9 +1204,9 @@ "description": "Automatic BASH completion for Symfony Console Component based applications.", "support": { "issues": "https://github.com/stecman/symfony-console-completion/issues", - "source": "https://github.com/stecman/symfony-console-completion/tree/v0.12.2" + "source": "https://github.com/stecman/symfony-console-completion/tree/v0.13.0" }, - "time": "2023-06-27T23:55:08+00:00" + "time": "2024-07-05T11:49:57+00:00" }, { "name": "symfony/config", @@ -2246,16 +2246,16 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.28.0", + "version": "v1.30.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb" + "reference": "0424dff1c58f028c451efff2045f5d92410bd540" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb", - "reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/0424dff1c58f028c451efff2045f5d92410bd540", + "reference": "0424dff1c58f028c451efff2045f5d92410bd540", "shasum": "" }, "require": { @@ -2269,9 +2269,6 @@ }, "type": "library", "extra": { - "branch-alias": { - "dev-main": "1.28-dev" - }, "thanks": { "name": "symfony/polyfill", "url": "https://github.com/symfony/polyfill" @@ -2308,7 +2305,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.28.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.30.0" }, "funding": [ { @@ -2324,7 +2321,7 @@ "type": "tidelift" } ], - "time": "2023-01-26T09:26:14+00:00" + "time": "2024-05-31T15:07:36+00:00" }, { "name": "symfony/polyfill-intl-grapheme", @@ -3494,16 +3491,16 @@ }, { "name": "doctrine/deprecations", - "version": "1.1.2", + "version": "1.1.3", "source": { "type": "git", "url": "https://github.com/doctrine/deprecations.git", - "reference": "4f2d4f2836e7ec4e7a8625e75c6aa916004db931" + "reference": "dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/deprecations/zipball/4f2d4f2836e7ec4e7a8625e75c6aa916004db931", - "reference": "4f2d4f2836e7ec4e7a8625e75c6aa916004db931", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab", + "reference": "dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab", "shasum": "" }, "require": { @@ -3535,9 +3532,9 @@ "homepage": "https://www.doctrine-project.org/", "support": { "issues": "https://github.com/doctrine/deprecations/issues", - "source": "https://github.com/doctrine/deprecations/tree/1.1.2" + "source": "https://github.com/doctrine/deprecations/tree/1.1.3" }, - "time": "2023-09-27T20:04:15+00:00" + "time": "2024-01-30T19:34:25+00:00" }, { "name": "doctrine/instantiator", @@ -3934,16 +3931,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": { @@ -3951,11 +3948,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", @@ -3981,7 +3979,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": [ { @@ -3989,29 +3987,31 @@ "type": "tidelift" } ], - "time": "2023-03-08T13:26:56+00:00" + "time": "2024-06-12T14:39:25+00:00" }, { "name": "nikic/php-parser", - "version": "v4.17.1", + "version": "v5.1.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" + "reference": "683130c2ff8c2739f4822ff7ac5c873ec529abd1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/683130c2ff8c2739f4822ff7ac5c873ec529abd1", + "reference": "683130c2ff8c2739f4822ff7ac5c873ec529abd1", "shasum": "" }, "require": { + "ext-ctype": "*", + "ext-json": "*", "ext-tokenizer": "*", - "php": ">=7.0" + "php": ">=7.4" }, "require-dev": { "ircmaxell/php-yacc": "^0.0.7", - "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" + "phpunit/phpunit": "^9.0" }, "bin": [ "bin/php-parse" @@ -4019,7 +4019,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.9-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -4043,26 +4043,27 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.17.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v5.1.0" }, - "time": "2023-08-13T19:53:39+00:00" + "time": "2024-07-01T20:03:41+00:00" }, { "name": "phar-io/manifest", - "version": "2.0.3", + "version": "2.0.4", "source": { "type": "git", "url": "https://github.com/phar-io/manifest.git", - "reference": "97803eca37d319dfa7826cc2437fc020857acb53" + "reference": "54750ef60c58e43759730615a392c31c80e23176" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/97803eca37d319dfa7826cc2437fc020857acb53", - "reference": "97803eca37d319dfa7826cc2437fc020857acb53", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176", + "reference": "54750ef60c58e43759730615a392c31c80e23176", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-phar": "*", "ext-xmlwriter": "*", "phar-io/version": "^3.0.1", @@ -4103,9 +4104,15 @@ "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", "support": { "issues": "https://github.com/phar-io/manifest/issues", - "source": "https://github.com/phar-io/manifest/tree/2.0.3" + "source": "https://github.com/phar-io/manifest/tree/2.0.4" }, - "time": "2021-07-20T11:28:43+00:00" + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2024-03-03T12:33:53+00:00" }, { "name": "phar-io/version", @@ -4275,28 +4282,35 @@ }, { "name": "phpdocumentor/reflection-docblock", - "version": "5.3.0", + "version": "5.4.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "622548b623e81ca6d78b721c5e029f4ce664f170" + "reference": "9d07b3f7fdcf5efec5d1609cba3c19c5ea2bdc9c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/622548b623e81ca6d78b721c5e029f4ce664f170", - "reference": "622548b623e81ca6d78b721c5e029f4ce664f170", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/9d07b3f7fdcf5efec5d1609cba3c19c5ea2bdc9c", + "reference": "9d07b3f7fdcf5efec5d1609cba3c19c5ea2bdc9c", "shasum": "" }, "require": { + "doctrine/deprecations": "^1.1", "ext-filter": "*", - "php": "^7.2 || ^8.0", + "php": "^7.4 || ^8.0", "phpdocumentor/reflection-common": "^2.2", - "phpdocumentor/type-resolver": "^1.3", + "phpdocumentor/type-resolver": "^1.7", + "phpstan/phpdoc-parser": "^1.7", "webmozart/assert": "^1.9.1" }, "require-dev": { - "mockery/mockery": "~1.3.2", - "psalm/phar": "^4.8" + "mockery/mockery": "~1.3.5", + "phpstan/extension-installer": "^1.1", + "phpstan/phpstan": "^1.8", + "phpstan/phpstan-mockery": "^1.1", + "phpstan/phpstan-webmozart-assert": "^1.2", + "phpunit/phpunit": "^9.5", + "vimeo/psalm": "^5.13" }, "type": "library", "extra": { @@ -4320,33 +4334,33 @@ }, { "name": "Jaap van Otterdijk", - "email": "account@ijaap.nl" + "email": "opensource@ijaap.nl" } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", "support": { "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues", - "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/5.3.0" + "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/5.4.1" }, - "time": "2021-10-19T17:43:47+00:00" + "time": "2024-05-21T05:55:05+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "1.7.3", + "version": "1.8.2", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "3219c6ee25c9ea71e3d9bbaf39c67c9ebd499419" + "reference": "153ae662783729388a584b4361f2545e4d841e3c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/3219c6ee25c9ea71e3d9bbaf39c67c9ebd499419", - "reference": "3219c6ee25c9ea71e3d9bbaf39c67c9ebd499419", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/153ae662783729388a584b4361f2545e4d841e3c", + "reference": "153ae662783729388a584b4361f2545e4d841e3c", "shasum": "" }, "require": { "doctrine/deprecations": "^1.0", - "php": "^7.4 || ^8.0", + "php": "^7.3 || ^8.0", "phpdocumentor/reflection-common": "^2.0", "phpstan/phpdoc-parser": "^1.13" }, @@ -4384,9 +4398,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.7.3" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.8.2" }, - "time": "2023-08-12T11:01:26+00:00" + "time": "2024-02-23T11:10:43+00:00" }, { "name": "phpro/grumphp-shim", @@ -4449,24 +4463,24 @@ }, { "name": "phpspec/prophecy", - "version": "v1.18.0", + "version": "v1.19.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "d4f454f7e1193933f04e6500de3e79191648ed0c" + "reference": "67a759e7d8746d501c41536ba40cd9c0a07d6a87" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/d4f454f7e1193933f04e6500de3e79191648ed0c", - "reference": "d4f454f7e1193933f04e6500de3e79191648ed0c", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/67a759e7d8746d501c41536ba40cd9c0a07d6a87", + "reference": "67a759e7d8746d501c41536ba40cd9c0a07d6a87", "shasum": "" }, "require": { "doctrine/instantiator": "^1.2 || ^2.0", "php": "^7.2 || 8.0.* || 8.1.* || 8.2.* || 8.3.*", "phpdocumentor/reflection-docblock": "^5.2", - "sebastian/comparator": "^3.0 || ^4.0 || ^5.0", - "sebastian/recursion-context": "^3.0 || ^4.0 || ^5.0" + "sebastian/comparator": "^3.0 || ^4.0 || ^5.0 || ^6.0", + "sebastian/recursion-context": "^3.0 || ^4.0 || ^5.0 || ^6.0" }, "require-dev": { "phpspec/phpspec": "^6.0 || ^7.0", @@ -4512,33 +4526,33 @@ ], "support": { "issues": "https://github.com/phpspec/prophecy/issues", - "source": "https://github.com/phpspec/prophecy/tree/v1.18.0" + "source": "https://github.com/phpspec/prophecy/tree/v1.19.0" }, - "time": "2023-12-07T16:22:33+00:00" + "time": "2024-02-29T11:52:51+00:00" }, { "name": "phpspec/prophecy-phpunit", - "version": "v2.0.2", + "version": "v2.2.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy-phpunit.git", - "reference": "9f26c224a2fa335f33e6666cc078fbf388255e87" + "reference": "16e1247e139434bce0bac09848bc5c8d882940fc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy-phpunit/zipball/9f26c224a2fa335f33e6666cc078fbf388255e87", - "reference": "9f26c224a2fa335f33e6666cc078fbf388255e87", + "url": "https://api.github.com/repos/phpspec/prophecy-phpunit/zipball/16e1247e139434bce0bac09848bc5c8d882940fc", + "reference": "16e1247e139434bce0bac09848bc5c8d882940fc", "shasum": "" }, "require": { "php": "^7.3 || ^8", - "phpspec/prophecy": "^1.3", - "phpunit/phpunit": "^9.1" + "phpspec/prophecy": "^1.18", + "phpunit/phpunit": "^9.1 || ^10.1 || ^11.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "2.x-dev" } }, "autoload": { @@ -4564,22 +4578,22 @@ ], "support": { "issues": "https://github.com/phpspec/prophecy-phpunit/issues", - "source": "https://github.com/phpspec/prophecy-phpunit/tree/v2.0.2" + "source": "https://github.com/phpspec/prophecy-phpunit/tree/v2.2.0" }, - "time": "2023-04-18T11:58:05+00:00" + "time": "2024-03-01T08:33:58+00:00" }, { "name": "phpstan/phpdoc-parser", - "version": "1.24.4", + "version": "1.29.1", "source": { "type": "git", "url": "https://github.com/phpstan/phpdoc-parser.git", - "reference": "6bd0c26f3786cd9b7c359675cb789e35a8e07496" + "reference": "fcaefacf2d5c417e928405b71b400d4ce10daaf4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/6bd0c26f3786cd9b7c359675cb789e35a8e07496", - "reference": "6bd0c26f3786cd9b7c359675cb789e35a8e07496", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/fcaefacf2d5c417e928405b71b400d4ce10daaf4", + "reference": "fcaefacf2d5c417e928405b71b400d4ce10daaf4", "shasum": "" }, "require": { @@ -4611,9 +4625,9 @@ "description": "PHPDoc parser with support for nullable, intersection and generic types", "support": { "issues": "https://github.com/phpstan/phpdoc-parser/issues", - "source": "https://github.com/phpstan/phpdoc-parser/tree/1.24.4" + "source": "https://github.com/phpstan/phpdoc-parser/tree/1.29.1" }, - "time": "2023-11-26T18:29:22+00:00" + "time": "2024-05-31T08:52:43+00:00" }, { "name": "phpstan/phpstan", @@ -4679,23 +4693,23 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.29", + "version": "9.2.31", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "6a3a87ac2bbe33b25042753df8195ba4aa534c76" + "reference": "48c34b5d8d983006bd2adc2d0de92963b9155965" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/6a3a87ac2bbe33b25042753df8195ba4aa534c76", - "reference": "6a3a87ac2bbe33b25042753df8195ba4aa534c76", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/48c34b5d8d983006bd2adc2d0de92963b9155965", + "reference": "48c34b5d8d983006bd2adc2d0de92963b9155965", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.15", + "nikic/php-parser": "^4.18 || ^5.0", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -4745,7 +4759,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.29" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.31" }, "funding": [ { @@ -4753,7 +4767,7 @@ "type": "github" } ], - "time": "2023-09-19T04:57:46+00:00" + "time": "2024-03-02T06:37:42+00:00" }, { "name": "phpunit/php-file-iterator", @@ -4998,45 +5012,45 @@ }, { "name": "phpunit/phpunit", - "version": "9.6.15", + "version": "9.6.20", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "05017b80304e0eb3f31d90194a563fd53a6021f1" + "reference": "49d7820565836236411f5dc002d16dd689cde42f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/05017b80304e0eb3f31d90194a563fd53a6021f1", - "reference": "05017b80304e0eb3f31d90194a563fd53a6021f1", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/49d7820565836236411f5dc002d16dd689cde42f", + "reference": "49d7820565836236411f5dc002d16dd689cde42f", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.3.1 || ^2", + "doctrine/instantiator": "^1.5.0 || ^2", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.10.1", - "phar-io/manifest": "^2.0.3", - "phar-io/version": "^3.0.2", + "myclabs/deep-copy": "^1.12.0", + "phar-io/manifest": "^2.0.4", + "phar-io/version": "^3.2.1", "php": ">=7.3", - "phpunit/php-code-coverage": "^9.2.28", - "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-code-coverage": "^9.2.31", + "phpunit/php-file-iterator": "^3.0.6", "phpunit/php-invoker": "^3.1.1", - "phpunit/php-text-template": "^2.0.3", - "phpunit/php-timer": "^5.0.2", - "sebastian/cli-parser": "^1.0.1", - "sebastian/code-unit": "^1.0.6", + "phpunit/php-text-template": "^2.0.4", + "phpunit/php-timer": "^5.0.3", + "sebastian/cli-parser": "^1.0.2", + "sebastian/code-unit": "^1.0.8", "sebastian/comparator": "^4.0.8", - "sebastian/diff": "^4.0.3", - "sebastian/environment": "^5.1.3", - "sebastian/exporter": "^4.0.5", - "sebastian/global-state": "^5.0.1", - "sebastian/object-enumerator": "^4.0.3", - "sebastian/resource-operations": "^3.0.3", - "sebastian/type": "^3.2", + "sebastian/diff": "^4.0.6", + "sebastian/environment": "^5.1.5", + "sebastian/exporter": "^4.0.6", + "sebastian/global-state": "^5.0.7", + "sebastian/object-enumerator": "^4.0.4", + "sebastian/resource-operations": "^3.0.4", + "sebastian/type": "^3.2.1", "sebastian/version": "^3.0.2" }, "suggest": { @@ -5081,7 +5095,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.15" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.20" }, "funding": [ { @@ -5097,20 +5111,20 @@ "type": "tidelift" } ], - "time": "2023-12-01T16:55:19+00:00" + "time": "2024-07-10T11:45:39+00:00" }, { "name": "sebastian/cli-parser", - "version": "1.0.1", + "version": "1.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/cli-parser.git", - "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", - "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b", "shasum": "" }, "require": { @@ -5145,7 +5159,7 @@ "homepage": "https://github.com/sebastianbergmann/cli-parser", "support": { "issues": "https://github.com/sebastianbergmann/cli-parser/issues", - "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.2" }, "funding": [ { @@ -5153,7 +5167,7 @@ "type": "github" } ], - "time": "2020-09-28T06:08:49+00:00" + "time": "2024-03-02T06:27:43+00:00" }, { "name": "sebastian/code-unit", @@ -5342,20 +5356,20 @@ }, { "name": "sebastian/complexity", - "version": "2.0.2", + "version": "2.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", - "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/25f207c40d62b8b7aa32f5ab026c53561964053a", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a", "shasum": "" }, "require": { - "nikic/php-parser": "^4.7", + "nikic/php-parser": "^4.18 || ^5.0", "php": ">=7.3" }, "require-dev": { @@ -5387,7 +5401,7 @@ "homepage": "https://github.com/sebastianbergmann/complexity", "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", - "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.3" }, "funding": [ { @@ -5395,20 +5409,20 @@ "type": "github" } ], - "time": "2020-10-26T15:52:27+00:00" + "time": "2023-12-22T06:19:30+00:00" }, { "name": "sebastian/diff", - "version": "4.0.5", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131" + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/74be17022044ebaaecfdf0c5cd504fc9cd5a7131", - "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ba01945089c3a293b01ba9badc29ad55b106b0bc", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc", "shasum": "" }, "require": { @@ -5453,7 +5467,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/4.0.5" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" }, "funding": [ { @@ -5461,7 +5475,7 @@ "type": "github" } ], - "time": "2023-05-07T05:35:17+00:00" + "time": "2024-03-02T06:30:58+00:00" }, { "name": "sebastian/environment", @@ -5528,16 +5542,16 @@ }, { "name": "sebastian/exporter", - "version": "4.0.5", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d" + "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", - "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/78c00df8f170e02473b682df15bfcdacc3d32d72", + "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72", "shasum": "" }, "require": { @@ -5593,7 +5607,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.5" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.6" }, "funding": [ { @@ -5601,20 +5615,20 @@ "type": "github" } ], - "time": "2022-09-14T06:03:37+00:00" + "time": "2024-03-02T06:33:00+00:00" }, { "name": "sebastian/global-state", - "version": "5.0.6", + "version": "5.0.7", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "bde739e7565280bda77be70044ac1047bc007e34" + "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bde739e7565280bda77be70044ac1047bc007e34", - "reference": "bde739e7565280bda77be70044ac1047bc007e34", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", + "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", "shasum": "" }, "require": { @@ -5657,7 +5671,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.6" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.7" }, "funding": [ { @@ -5665,24 +5679,24 @@ "type": "github" } ], - "time": "2023-08-02T09:26:13+00:00" + "time": "2024-03-02T06:35:11+00:00" }, { "name": "sebastian/lines-of-code", - "version": "1.0.3", + "version": "1.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/lines-of-code.git", - "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", - "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5", "shasum": "" }, "require": { - "nikic/php-parser": "^4.6", + "nikic/php-parser": "^4.18 || ^5.0", "php": ">=7.3" }, "require-dev": { @@ -5714,7 +5728,7 @@ "homepage": "https://github.com/sebastianbergmann/lines-of-code", "support": { "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", - "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.4" }, "funding": [ { @@ -5722,7 +5736,7 @@ "type": "github" } ], - "time": "2020-11-28T06:42:11+00:00" + "time": "2023-12-22T06:20:34+00:00" }, { "name": "sebastian/object-enumerator", @@ -5901,16 +5915,16 @@ }, { "name": "sebastian/resource-operations", - "version": "3.0.3", + "version": "3.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", - "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/05d5692a7993ecccd56a03e40cd7e5b09b1d404e", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e", "shasum": "" }, "require": { @@ -5922,7 +5936,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -5943,8 +5957,7 @@ "description": "Provides a list of PHP built-in functions that operate on resources", "homepage": "https://www.github.com/sebastianbergmann/resource-operations", "support": { - "issues": "https://github.com/sebastianbergmann/resource-operations/issues", - "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.4" }, "funding": [ { @@ -5952,7 +5965,7 @@ "type": "github" } ], - "time": "2020-09-28T06:45:17+00:00" + "time": "2024-03-14T16:00:52+00:00" }, { "name": "sebastian/type", @@ -6259,16 +6272,16 @@ }, { "name": "theseer/tokenizer", - "version": "1.2.2", + "version": "1.2.3", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96" + "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b2ad5003ca10d4ee50a12da31de12a5774ba6b96", - "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", + "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", "shasum": "" }, "require": { @@ -6297,7 +6310,7 @@ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "support": { "issues": "https://github.com/theseer/tokenizer/issues", - "source": "https://github.com/theseer/tokenizer/tree/1.2.2" + "source": "https://github.com/theseer/tokenizer/tree/1.2.3" }, "funding": [ { @@ -6305,7 +6318,7 @@ "type": "github" } ], - "time": "2023-11-20T00:12:19+00:00" + "time": "2024-03-03T12:36:25+00:00" }, { "name": "webmozart/assert", @@ -6373,5 +6386,5 @@ "prefer-lowest": false, "platform": [], "platform-dev": [], - "plugin-api-version": "2.3.0" + "plugin-api-version": "2.6.0" } diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 95745260..38bfc5e7 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,26 +1,22 @@ - + - + - - - - ./tests - - - - - ./ - - ./bin - ./tests - ./vendor - - - + + + ./tests + + + + + ./ + + + ./bin + ./tests + ./vendor + + diff --git a/tests/unit/CliTest.php b/tests/unit/CliTest.php index d01c50fd..a95b4382 100644 --- a/tests/unit/CliTest.php +++ b/tests/unit/CliTest.php @@ -59,23 +59,28 @@ protected function setUp(): void { * * @test */ - public function testExecute() :void { + public function testExecute(): void { $this->assertEquals("Welcome to Acquia CMS Starter Kit installer", $this->acquiaCli->headline); $this->assertEquals($this->projectDirectory . "/assets/acquia_cms.icon.ascii", $this->acquiaCli->getLogo()); - $this->assertEquals($this->getAcmsFileContents(), $this->acquiaCli->getAcquiaCmsFile($this->projectDirectory . '/acms/acms.yml')); + $this->assertEquals(self::getAcmsFileContents(), $this->acquiaCli->getAcquiaCmsFile($this->projectDirectory . '/acms/acms.yml')); } /** + * Test the alteration of modules and theme. + * * @dataProvider alterModuleThemesDataProvider */ public function testAlterModuleThemes(string $bundle, array $userValues, array $expected, string $message = ''): void { - $starter_kit = $this->getAcmsFileContents()['starter_kits'][$bundle]; + $starter_kit = self::getAcmsFileContents()['starter_kits'][$bundle]; $expected = array_replace_recursive($starter_kit, ...$expected); $this->acquiaCli->alterModulesAndThemes($starter_kit, $userValues); $this->assertEquals($starter_kit, $expected, $message); } + /** + * Test the low code package. + */ public function testAlterPackagesForLowCode(): void { $container = $this->createMock(ContainerInterface::class); $package = $this->createMock(Packages::class); @@ -170,7 +175,7 @@ private function createPackage(array $data): object { /** * An array of default contents for acms/acms.yml file. */ - protected function getAcmsFileContents() :array { + public static function getAcmsFileContents(): array { return [ "starter_kits" => [ "acquia_cms_enterprise_low_code" => [ @@ -515,8 +520,11 @@ public static function getGmapsKey(): array { /** * Function to return data provider for method: alterModulesAndThemes(). + * + * @return array[] + * Returns the list of modules and theme. */ - public function alterModuleThemesDataProvider() :array { + public static function alterModuleThemesDataProvider(): array { foreach (['acquia_cms_enterprise_low_code', 'acquia_cms_community', 'acquia_cms_headless'] as $bundle) { $returnArray = [ [ @@ -528,12 +536,12 @@ public function alterModuleThemesDataProvider() :array { [ "modules" => [ "require" => array_unique(array_merge( - $this->getAcmsFileContents()['starter_kits'][$bundle]['modules']['require'], - $this->getUpdatedModulesThemesArray($bundle, 'demo_content'), + self::getAcmsFileContents()['starter_kits'][$bundle]['modules']['require'], + self::getUpdatedModulesThemesArray($bundle, 'demo_content'), )), "install" => array_unique(array_merge( - $this->getAcmsFileContents()['starter_kits'][$bundle]['modules']['install'], - $this->getUpdatedModulesThemesArray($bundle, 'demo_content'), + self::getAcmsFileContents()['starter_kits'][$bundle]['modules']['install'], + self::getUpdatedModulesThemesArray($bundle, 'demo_content'), )), ], ], @@ -553,12 +561,12 @@ public function alterModuleThemesDataProvider() :array { [ "modules" => [ "require" => array_unique(array_merge( - $this->getAcmsFileContents()['starter_kits'][$bundle]['modules']['require'], - $this->getUpdatedModulesThemesArray($bundle, 'content_model'), + self::getAcmsFileContents()['starter_kits'][$bundle]['modules']['require'], + self::getUpdatedModulesThemesArray($bundle, 'content_model'), )), "install" => array_unique(array_merge( - $this->getAcmsFileContents()['starter_kits'][$bundle]['modules']['install'], - $this->getUpdatedModulesThemesArray($bundle, 'content_model'), + self::getAcmsFileContents()['starter_kits'][$bundle]['modules']['install'], + self::getUpdatedModulesThemesArray($bundle, 'content_model'), )), ], ], @@ -577,8 +585,8 @@ public function alterModuleThemesDataProvider() :array { [ [ "modules" => [ - "require" => $this->getAcmsFileContents()['starter_kits'][$bundle]['modules']['require'], - "install" => $this->getAcmsFileContents()['starter_kits'][$bundle]['modules']['install'], + "require" => self::getAcmsFileContents()['starter_kits'][$bundle]['modules']['require'], + "install" => self::getAcmsFileContents()['starter_kits'][$bundle]['modules']['install'], ], ], [ @@ -589,6 +597,7 @@ public function alterModuleThemesDataProvider() :array { ], ]; } + return $returnArray; } @@ -600,7 +609,7 @@ public function alterModuleThemesDataProvider() :array { * @param string $question_type * A question machine_name. */ - public function getUpdatedModulesThemesArray(string $bundle, string $question_type = ''): array { + public static function getUpdatedModulesThemesArray(string $bundle, string $question_type = ''): array { switch ($question_type) : case 'content_model': $packages = [ diff --git a/tests/unit/Helpers/InstallerQuestionsTest.php b/tests/unit/Helpers/InstallerQuestionsTest.php index e1c6c401..18ba6b94 100644 --- a/tests/unit/Helpers/InstallerQuestionsTest.php +++ b/tests/unit/Helpers/InstallerQuestionsTest.php @@ -99,7 +99,7 @@ protected function setUp(): void { * * @dataProvider providerBundleBuild */ - public function testGetQuestionsForBundleBuild(string $bundle, array $questions) :void { + public function testGetQuestionsForBundleBuild(string $bundle, array $questions): void { $this->assertEquals($questions, $this->installerQuestions->getQuestions($this->acmsBuildQuestions, $bundle)); } @@ -113,7 +113,7 @@ public function testGetQuestionsForBundleBuild(string $bundle, array $questions) * * @dataProvider providerBundleInstall */ - public function testGetQuestionsForBundleInstall(string $bundle, array $questions) :void { + public function testGetQuestionsForBundleInstall(string $bundle, array $questions): void { $this->assertEquals($questions, $this->installerQuestions->getQuestions($this->acmsInstallQuestions, $bundle)); } @@ -131,7 +131,7 @@ public function testGetQuestionsForBundleInstall(string $bundle, array $question * * @dataProvider providerDefaultValue */ - public function testQuestionDefaultValue(array $actual, string $expected, string $key = '', array $envVariables = []) :void { + public function testQuestionDefaultValue(array $actual, string $expected, string $key = '', array $envVariables = []): void { if ($envVariables) { foreach ($envVariables as $envVariable => $value) { putenv("$envVariable=$value"); @@ -154,40 +154,29 @@ public function testQuestionDefaultValue(array $actual, string $expected, string * * @dataProvider dataShouldAskQuestion */ - public function testShouldAskQuestion(array $question, array $userInputValues, bool $expected, string $exception = '') : void { + public function testShouldAskQuestion(array $question, array $userInputValues, bool $expected, string $exception = ''): void { if ($exception) { $this->expectExceptionMessageMatches($exception); } $this->assertEquals($expected, $this->installerQuestions->shouldAskQuestion($question, $userInputValues)); } - /** - * Returns an array of dummy question. - * - * @return array - * Returns an array of dummy question. - */ - protected function dummyQuestion(): array { - return [ - 'dependencies' => [ - 'starter_kits' => 'acquia_cms_enterprise_low_code', - ], - 'question' => "Please provide the Site Studio Organization Key", - 'warning' => "The Site Studio Organization key is not set. The Site Studio packages won't get imported.\nYou can set the key later from: /admin/cohesion/configuration/account-settings to import Site Studio packages.", - ]; - } - /** * Returns an array of dataProvider for method: shouldAskQuestion(). * * @return array[] * Returns an array of dataProvider. */ - public function dataShouldAskQuestion(): array { - $dummyQuestion = $this->dummyQuestion(); + public static function dataShouldAskQuestion(): array { return [ [ - $dummyQuestion, + [ + 'dependencies' => [ + 'starter_kits' => 'acquia_cms_enterprise_low_code', + ], + 'question' => "Please provide the Site Studio Organization Key", + 'warning' => "The Site Studio Organization key is not set. The Site Studio packages won't get imported.\nYou can set the key later from: /admin/cohesion/configuration/account-settings to import Site Studio packages.", + ], [ 'demo_content' => 'ALL', ], @@ -202,7 +191,7 @@ public function dataShouldAskQuestion(): array { * @return array[] * Returns an array of values. */ - public function providerDefaultValue(): array { + public static function providerDefaultValue(): array { return [ [ CliTest::getContentModel()['content_model'], @@ -233,7 +222,7 @@ public function providerDefaultValue(): array { * @return array[] * Sets of arguments to pass to the test method. */ - public function providerBundleBuild() :array { + public static function providerBundleBuild(): array { return [ [ 'acquia_cms_enterprise_low_code', @@ -270,7 +259,7 @@ public function providerBundleBuild() :array { * @return array[] * Sets of arguments to pass to the test method. */ - public function providerBundleInstall() :array { + public static function providerBundleInstall(): array { return [ [ 'acquia_cms_enterprise_low_code', diff --git a/tests/unit/Helpers/Parsers/JsonParserTest.php b/tests/unit/Helpers/Parsers/JsonParserTest.php index 99531575..983dc111 100644 --- a/tests/unit/Helpers/Parsers/JsonParserTest.php +++ b/tests/unit/Helpers/Parsers/JsonParserTest.php @@ -22,7 +22,7 @@ class JsonParserTest extends TestCase { * * @dataProvider downloadPackagesDataProvider */ - public function testDownloadPackages(array $actual, array $expected) :void { + public function testDownloadPackages(array $actual, array $expected): void { $this->assertEquals($expected, JsonParser::downloadPackages($actual)); } @@ -36,14 +36,14 @@ public function testDownloadPackages(array $actual, array $expected) :void { * * @dataProvider installPackagesDataProvider */ - public function testInstallPackages(array $actual, array $expected) :void { + public function testInstallPackages(array $actual, array $expected): void { $this->assertEquals($expected, JsonParser::installPackages($actual)); } /** * Provides the data to test: testDownloadPackages(). */ - public function downloadPackagesDataProvider(): array { + public static function downloadPackagesDataProvider(): array { return [ [ ["acquia_cms_common", "acquia/cohesion", "drupal/acquia_cms_article", "acquia/cohesion_theme"], @@ -59,7 +59,7 @@ public function downloadPackagesDataProvider(): array { /** * Provides the data to test: testInstallPackages(). */ - public function installPackagesDataProvider(): array { + public static function installPackagesDataProvider(): array { return [ [ ["acquia_cms_common", "acquia/cohesion", "drupal/acquia_cms_article", "acquia/cohesion_theme"], diff --git a/tests/unit/Helpers/Parsers/PHPParserTest.php b/tests/unit/Helpers/Parsers/PHPParserTest.php index 3c7aaf14..341a885a 100644 --- a/tests/unit/Helpers/Parsers/PHPParserTest.php +++ b/tests/unit/Helpers/Parsers/PHPParserTest.php @@ -24,7 +24,7 @@ class PHPParserTest extends TestCase { * * @dataProvider parseEnvVariablesDataProvider */ - public function testPhpEnvVars(string $actual, string $expected, array $envVariables = []) :void { + public function testPhpEnvVars(string $actual, string $expected, array $envVariables = []): void { if ($envVariables) { foreach ($envVariables as $key => $value) { putenv("$key=$value"); @@ -36,7 +36,7 @@ public function testPhpEnvVars(string $actual, string $expected, array $envVaria /** * @dataProvider parseValidQuestionExpression */ - public function testParseValidQuestion(string $actual, array $expected, string $exception = NULL) :void { + public function testParseValidQuestion(string $actual, array $expected, string $exception = NULL): void { if ($exception) { $this->expectException($exception); } @@ -46,7 +46,7 @@ public function testParseValidQuestion(string $actual, array $expected, string $ /** * Provides the data to test: testParseQuestionExpression(). */ - public function parseValidQuestionExpression(): array { + public static function parseValidQuestionExpression(): array { return [ [ '${site_studio} == "yes"', @@ -87,7 +87,7 @@ public function parseValidQuestionExpression(): array { /** * Provides the data to test: testInstallPackages(). */ - public function parseEnvVariablesDataProvider(): array { + public static function parseEnvVariablesDataProvider(): array { return [ [ 'Static Value', diff --git a/tests/unit/Helpers/Process/GenericCommandTest.php b/tests/unit/Helpers/Process/GenericCommandTest.php index ddedc975..59bae217 100644 --- a/tests/unit/Helpers/Process/GenericCommandTest.php +++ b/tests/unit/Helpers/Process/GenericCommandTest.php @@ -47,7 +47,7 @@ protected function setUp(): void { /** * Test exception for generic command. */ - public function testExceptionCommand() :void { + public function testExceptionCommand(): void { $this->expectExceptionMessage("Command can not be empty. Provide command name. Ex: drush, php etc."); $this->genericCommand->prepare()->run(); } @@ -76,7 +76,7 @@ public function testExecuteCommandQuietly() :void { * * @dataProvider dataProviderWithEnvVariable */ - public function testExecuteCommandWithEnvironmentVariables(array $actual, string $expected) :void { + public function testExecuteCommandWithEnvironmentVariables(array $actual, string $expected): void { $this->genericCommand->setCommand('php'); $output = $this->genericCommand->prepare([ '-r', @@ -89,7 +89,7 @@ public function testExecuteCommandWithEnvironmentVariables(array $actual, string /** * An array of some commands to execute. */ - public function dataProviderWithEnvVariable() :array { + public static function dataProviderWithEnvVariable(): array { return [ [ [ diff --git a/tests/unit/Helpers/Traits/StatusMessageTraitTest.php b/tests/unit/Helpers/Traits/StatusMessageTraitTest.php index 1c8ac29a..dc981442 100644 --- a/tests/unit/Helpers/Traits/StatusMessageTraitTest.php +++ b/tests/unit/Helpers/Traits/StatusMessageTraitTest.php @@ -23,7 +23,7 @@ class StatusMessageTraitTest extends TestCase { * * @dataProvider styleDataProvider */ - public function testStyle(array $actual, array $expected) :void { + public function testStyle(array $actual, array $expected): void { $this->assertEquals($this->style(...$actual), $expected); } @@ -33,7 +33,7 @@ public function testStyle(array $actual, array $expected) :void { * @return array[] * Returns an array of actual/expected data. */ - public function styleDataProvider() { + public static function styleDataProvider(): array { return [ [ ['This is headline message.', 'headline'], diff --git a/tests/unit/Helpers/Traits/UserInputTraitTest.php b/tests/unit/Helpers/Traits/UserInputTraitTest.php index 03ad58f6..1c4a787f 100644 --- a/tests/unit/Helpers/Traits/UserInputTraitTest.php +++ b/tests/unit/Helpers/Traits/UserInputTraitTest.php @@ -23,7 +23,7 @@ class UserInputTraitTest extends TestCase { * * @dataProvider styleQuestionDataProvider */ - public function testStyle(array $actual, string $expected) :void { + public function testStyle(array $actual, string $expected): void { $this->assertEquals($this->styleQuestion(...$actual), $expected); } @@ -33,7 +33,7 @@ public function testStyle(array $actual, string $expected) :void { * @return array[] * Returns an array of actual/expected data. */ - public function styleQuestionDataProvider() :array { + public static function styleQuestionDataProvider(): array { return [ [ ['Please enter the Site Studio API Key', 'inter-abcd-47d4kf7'], diff --git a/tests/unit/Helpers/UtilityTest.php b/tests/unit/Helpers/UtilityTest.php index 746cdce5..3495d981 100644 --- a/tests/unit/Helpers/UtilityTest.php +++ b/tests/unit/Helpers/UtilityTest.php @@ -19,7 +19,7 @@ class UtilityTest extends TestCase { * * @dataProvider dataProviderDirectory */ - public function testNormalizeDirectoryPath(string $expected, string $actual) :void { + public function testNormalizeDirectoryPath(string $expected, string $actual): void { $this->assertEquals($expected, Utility::normalizePath($actual)); } @@ -108,7 +108,7 @@ public function testRemoveValueByKey(): void { * @return array * Returns an array of directories path. */ - public function dataProviderDirectory() :array { + public static function dataProviderDirectory(): array { return [ [ "/acquia/acquia-cms-project", @@ -132,7 +132,7 @@ public function dataProviderDirectory() :array { /** * Tests the method generateRandomPassword(). */ - public function testGeneratedPassword() :void { + public function testGeneratedPassword(): void { $password = Utility::generateRandomPassword(12); $this->assertMatchesRegularExpression("/(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[^\da-zA-Z]).{8,}/", $password); }