Add QA Tools / Linters
We want to add CI/CD tools to all PDS Interop PHP repositories that are dependencies for this repository.
This ticket serves as full list of all the steps that need to be taken. For all repositories the steps are more or less the same:
- Create a
.github/workflowsdirectory - Create a YAML workflow file to lint for PHP syntax errors
- Create a YAML workflow file to check for PHP version compatibility (PHP Compat)
- Create a YAML workflow file to check for style violations (PHP CodeSniffer)
- Create a YAML workflow file to do security checks
- Create a YAML workflow file to run PHPUnit tests (similar to
tests.yml)
This means our worklist is:
-
solid-nextcloud- [x] Workflow to lint for PHP syntax errors
- [x] Workflow to check for PHP version compatibility
- [x] Workflow to check for style violations
- [x] Workflow to do security checks
- [ ] ~~Workflow to run PHPUnit tests~~ see #81
-
php-solid-auth- [x] Workflow to lint for PHP syntax errors
- [x] Workflow to check for PHP version compatibility
- [ ] Workflow to check for style violations
- [x] Workflow to do security checks
- [x] Workflow to run PHPUnit tests
-
php-solid-crud- [x] Workflow to lint for PHP syntax errors
- [x] Workflow to check for PHP version compatibility
- [ ] Workflow to check for style violations
- [x] Workflow to do security checks
- [x] Workflow to run PHPUnit tests
-
flysystem-nextcloud- [x] Workflow to lint for PHP syntax errors
- [x] Workflow to check for PHP version compatibility
- [ ] Workflow to check for style violations
- [x] Workflow to do security checks
- [x] Workflow to run PHPUnit tests
-
flysystem-rdf- [x] Workflow to lint for PHP syntax errors
- [x] Workflow to check for PHP version compatibility
- [ ] Workflow to check for style violations
- [x] Workflow to do security checks
- [x] Workflow to run PHPUnit tests
If so desired, this list can be broken out into separate tickets in each repo.
PRs for linting PHP:
https://github.com/pdsinterop/php-solid-crud/pull/17 https://github.com/pdsinterop/php-solid-auth/pull/21 https://github.com/pdsinterop/flysystem-nextcloud/pull/6 https://github.com/pdsinterop/flysystem-rdf/pull/8
PRs for PHP version sniff:
https://github.com/pdsinterop/php-solid-auth/pull/22 https://github.com/pdsinterop/php-solid-crud/pull/18 https://github.com/pdsinterop/flysystem-nextcloud/pull/7 https://github.com/pdsinterop/flysystem-rdf/pull/9
Since the security check only validates dependancies, we are only adding it to the solid-nextcloud repo:
https://github.com/pdsinterop/solid-nextcloud/pull/79
Above PRs are merged.
Adding PHP version sniff for solid-nextcloud: https://github.com/pdsinterop/solid-nextcloud/pull/80
Above PR is merged.
PHPunit for flysystem/nextcloud: https://github.com/pdsinterop/flysystem-nextcloud/pull/9
PHPUnit for php-solid-crud: https://github.com/pdsinterop/php-solid-crud/pull/20
PHPunit for php-solid-auth: https://github.com/pdsinterop/php-solid-auth/pull/24
PHP Code standard added in 3aa3097c5eb866b823818402a6d6fdcc3222402b and b801021884426e2e299ed2fefe9171354e6caae8