pantheon-systems / site-audit-tool
Drush global extension to run Site Audit checks on Drush 8 and 9
Installs: 3 998
Dependents: 0
Suggesters: 0
Security: 0
Stars: 7
Watchers: 36
Forks: 3
Open Issues: 3
Type:drupal-drush
Requires
- php: >=5.6
Requires (Dev)
- composer/installers: ^1.2
- drupal/core-composer-scaffold: ^8.8.1
- drupal/core-recommended: ^8.8
- drupal/php: ^1
- drush/drush: ^8.3.3 || ^10.2.2
- g1a/composer-test-scenarios: ^3.0.2
- pantheon-systems/drupal-integrations: ^8
- phpunit/phpunit: ^6.5
- symfony/filesystem: ^3.4.28
- webflo/drupal-finder: ^1.1.0
- webmozart/path-util: ^2.3
- zaporylie/composer-drupal-optimizations: ^1.0.2
This package is auto-updated.
Last update: 2021-03-25 12:46:45 UTC
README
This is an experimental Drush extension.
Goal: Create a Global Drush command that runs all of the checks in the Site Audit 2.x branch.
Potential future goal: Share checks between the Global Drush command in the Site Audit 3.x branch.
See the #3052993 in the Site Audit issue queue.
Usage
Ideally, this Drush command will become a dependency of the Site Audit module; if that happens, it will be available once the Site Audit module is installed into a Composer-managed site.
You may also install this module to any location that Drush searches for global or site-local commands. It does not need its vendor directory.
Development
In development, clone this repository, then set up the System Under Test (sut) via:
composer install
composer drupal:scaffold
That will set up your local project to run and test with Drush 9. To use Drush 8 instead:
composer scenario drush8
The Composer Test Scenarios project is used to manage the Composer dependencies needed to test different scenarios of this project. Running composer scenario
is like running composer install
; it will install the appropriate dependencies for the requested testing scenario. Run composer install
to return to the default installation.
To use this extension as a global Drush command, set up your global drush.yml file as follows:
drush:
paths:
include:
- '${env.home}/path/to/drush-extensions'
Then install this project to ~/path/to/drush-extensions/Commands/site-audit-tool
Running Tests
Set up for 'development' as described in "Development" section. Then, run:
composer test
Ad-hoc Testing
In development:
composer drush audit:best-practices
This will run the given Drush command against a local test Drupal site, the "system under test". Run the tests once to install the Drupal site.