[D7] GitLab CI integration for core

Created on 13 September 2023, 10 months ago
Updated 21 December 2023, 6 months ago

Problem/Motivation

We've been trying to reproduce core testing with DrupalCI on GitLab CI in this project: https://www.drupal.org/project/gitlab_ci_testbed_for_drupal_core

There are regular updates on the progress in the #gitlab community slack channel as well as on issues created in that project.

Drupal 10+ is already using GitLab CI based on the suggestion made here 📌 GitLab CI integration for core Needs work .

It is time now to do the same for Drupal 7.

Steps to reproduce

Drupal 7 core is not currently configured to run tests in GitLab CI.

Proposed resolution

Add the GitLab CI related files, and start testing DrupalCI and GitLab CI in parallel. Then consider turning off some DrupalCI tasks when GitLab CI seems stable enough to make the switch.

---------------

The MR currently contains the base settings for D7 testing according to the D10 committed code (pipeline.yml, .gitlab-ci.yml, run-tests.sh), with these changes:

  • tests combinations are according to the comment #4 (the current status in DrupalCI) -with the exception of PHP 7.2/MySQL 5.6, where the PHP 7.2/MySQL 5.7 is used instead (MySQL 5.6 was not working) and PHP 8.2/pgsql-13.5, where PHP 8.2/pgsql-14.1 is used instead (PostgreSQL 14 was not working in DrupalCI)
  • .htaccess-parent part is needed for D7 to work correctly in the CI in subdirectory
  • it includes this issue: 📌 Document new arguments in run-tests.sh RTBC
  • (already committed in D10 as well)
  • (already committed in D10 as well)
  • SQLite testing is working unlike in the D10 setup
  • default testing is against PHP 8.1 (as we have in DrupalCI currently)
  • there is no linting in D7 currently, so the patch adds only PHP compatibility check via PHPCS and only on changed files (we cannot run Drupal standards check, as it was not possible to restrict PHP version to PHP 5.6)
  • Drupal 7 is installed via drush si, so it needed to use different MySQL database name (not the system mysql database)

Remaining tasks

MR.

User interface changes

None.

API changes

None.

Data model changes

None.

Release notes snippet

Drupal core now runs tests in GitLab CI.

📌 Task
Status

Fixed

Version

7.0 ⚰️

Component
PHPUnit 

Last updated about 20 hours ago

Created by

🇪🇸Spain fjgarlin

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024