Problem/Motivation
Let's show folks how to make a DrupalCI build file that doesn't run any tests, but does perform other code-quality tasks.
Proposed resolution
Use https://git.drupalcode.org/project/gitlab_templates/-/blob/1.0.x/gitlab-...
See https://www.drupal.org/project/infrastructure/issues/3265092#comment-149...
Remaining tasks
User interface changes
API changes
Data model changes
| Comment | File | Size | Author |
|---|---|---|---|
| #17 | 3014492-17.patch | 3.07 KB | andypost |
| #17 | interdiff.txt | 1.2 KB | andypost |
Issue fork examples-3014492
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
mile23Adding a CS-only drupalci.yml file. Revert drupalci.yml before committing.
Comment #4
mile23Forcing a phpcs scan of all files with documentation about it.
Comment #5
mile23Comment #7
mile23See some analysis about this test result: #2990645-33: "Build Successful" is treated as a test failure
Comment #8
andypostComment #9
mile23The purpose of this issue was to show how to do CS-only tests using drupalci.yml, and to do a proof of concept for the issue mentioned in #7.
We won't have any BC code paths as in #3069389: [Policy, no patch] Determine and document best practices for providing backwards compatibility code paths expected to be removed in the next major version. because the BC in core is provided for applications like this project. To deal with core deprecations within contrib, you just use the new API or whatever.
Comment #10
andypostLet's see current state, we sprinted on #3072416: [Meta] Drupal 9 Deprecated Code Report
Comment #12
jungleShould we rename
drupalci.ymltodrupalci.yml.example, and add a REAMDME? meanwhile, in the README, pointing to the official doc https://www.drupal.org/drupalorg/docs/drupal-ciComment #14
andypostPhpstan still reports some https://dispatcher.drupalci.org/job/drupal8_contrib_patches/36486/artifa...
Comment #15
jungleRe #14.
Fixed by the two issues.
#3072419: Remove all WebTestBase examples
#3143053: Fix the call to deprecated constant FILE_EXISTS_RENAME and FILE_EXISTS_REPLACE
Comment #16
andypostWe should remove simpletests from here as well + add few sniffers from core's file
Comment #17
andypostBit more clean-up
Comment #18
jungleDiscussed with @andypost on slack, we agreed on removing the customized phpcs.xml.dist and .drupalci.yml, to use the ones in the core. see https://drupal.slack.com/archives/C5Y5E9TBK/p1590565800069200
Comment #19
andypostNo, phpcs.xml.dist needed as example
But custom drupalci file is pita sync with core for sure
Comment #20
jungleSee #8, so does this mean nothing to commit/to do further there?
Comment #24
vishaljd commentedComment #25
jungleTo me, the documentation of DrupalCI customization is for Core development mainly. Rescope this, and hope that CS violations can be detected via Gitlab CI
Requested access to Gitlab CI #3261803: Using GitLab CI instead of Drupal CI
Comment #26
jungleComment #27
jungleComment #28
jungleComment #31
jungleComment #32
jungleComment #34
jungleThere are failed tests to be fixed, suppressed temporarily in the .gitlab-ci.yml file with
allow_failure: trueComment #35
jungleSee https://git.drupalcode.org/project/examples/-/jobs/40216 for failed tests.