test: #3614680 Add a pre-test that builds and installs Educare on Drupal CMS, and fix the patches wiring

Issue: https://www.drupal.org/project/educare/issues/3614680

Follow-up to !24 (merged), which merged before these three fixes were ready. As it stands on 1.0.x the Drupal CMS wiring cannot complete an install — this MR closes that and adds the job that proves it.

Problem/Motivation

!24 landed the wiring script with allowed-dependency-patches only. That allowlist does not stop cweagans/composer-patches from attempting a dependency's patch, and drupal/ai_context declares one with a path relative to the project root:

The "patches/canvas-3575644-string-long-regex-ai-context-item.patch" file
could not be downloaded: Failed to open stream: No such file or directory

Such a path only resolves from a root that happens to ship that file, so composer require drupal/educare aborts on a plain drupal/cms base before the install begins. varbase_project already solves this by ignoring drupal/* and naming ai_context explicitly.

Nothing exercised the script either, so it could rot silently and only break for whoever next tried Educare off a Varbase base.

Proposed resolution

  • scripts/assets/drupal-cms.composer.json — match varbase_project's patches block exactly: add ignore-dependency-patches: ["drupal/*", "drupal/ai_context"], and add the missing vardot/drupal-core-patches to the allowlist.
  • .gitlab-ci.yml — add 🧩 Install Educare site template on Drupal CMS (pre-test, needs: [], allow_failure: false), the counterpart to 📦 Install Educare site template (varbase). It builds a plain drupal/cms codebase, runs the wiring script, requires the checked-out recipe, and installs the template through the Drupal CMS installer — asserting the outcome rather than trusting exit codes: recipe and Canvas present, the allow-plugins entries and both patch lists set, at least six libraries declared, and vartheme_bs5_educare the default theme after install.
  • scripts/README.md — replace the "Known limit" paragraph. It claimed the install fails in the recipe config batch on a plain Drupal CMS base; that is no longer true (see below), so it is replaced with what the job actually verifies.

The path repository is configured with "options":{"symlink":false}. A symlinked recipes/educare points back at the project directory that contains the build, and any recursive scan then loops until Too many levels of symbolic links.

Testing

Run locally with gitlab-ci-local on a plain drupal/cms codebase — PASS in 12 minutes:

[success] Installation complete.
Drupal version : 11.4.5
Default theme  : vartheme_bs5_educare
Database       : Connected

It took three runs to get there, and each failure was a real defect this job exists to catch:

  1. 4 min — died in patch resolution on drupal/ai_context's relative path → fixed by ignore-dependency-patches.
  2. 9.6 min — cleared patch resolution, then died on Too many levels of symbolic links → fixed by symlink: false.
  3. 12 min — install completes, theme asserted.

So Educare installs on a plain Drupal CMS base, which is why the README's known-limit claim had to go rather than ship a statement the CI job disproves.

AI-Generated: Yes

Checkpoints:

  • File an issue
  • Addition/Change/Update/Fix
  • Testing to ensure no regression
  • Automated unit testing coverage
  • Automated functional testing coverage
  • UX/UI designer responsibilities
  • Readability
  • Accessibility
  • Performance
  • Security
  • Developer Documentation
  • User Guide Documentation
  • Reviewed by human
  • Code review by maintainers
  • Full testing and approval
  • Credit contributors
  • Review with the product owner
  • Release notes snippet
  • Release
Edited by Rajab Natshah

Merge request reports

Loading