Core composer tests should use local composer vs host composer

Created on 12 November 2020, about 4 years ago
Updated 17 October 2023, about 1 year ago

Problem/Motivation

ComposerProjectTemplatesTest is currently fails in HEAD when using the 7.4.x/7.3.x php containers.

This is due to the fact that the containers are built every day, and on Oct 28th, Composer 2 was released, thus upgrading those containers specifically.

If we build any new containers, HEAD will break.

Steps to reproduce

Run a core test using 7.4.x-dev or 7.3.x-dev php containers:
See https://www.drupal.org/pift-ci-job/1879647 β†’

Proposed resolution

The version of composer installed on the container should not be the one core tests rely on. We should change any invocations of 'composer' to ./vendor/bin/composer to ensure that we are using the version of composer that our dev dependencies specify for our tests.

We should open *another* followup to determine why our test fails in composer 2, or fix it as part of
https://www.drupal.org/project/drupal/issues/3128631 β†’

Remaining tasks

Write a patch

User interface changes

API changes

Data model changes

Release notes snippet

πŸ› Bug report
Status

Active

Version

11.0 πŸ”₯

Component
ComposerΒ  β†’

Last updated 15 days ago

No maintainer
Created by

πŸ‡ΊπŸ‡ΈUnited States Mixologic Portland, OR

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • First commit to issue fork.
  • πŸ‡ΊπŸ‡ΈUnited States bradjones1 Digital Nomad Life

    Rebased. Ran into this because I was trying to replicate a test failure, but I mostly run my tests in a container which does not have composer in the PATH, and it's not present in the install. Not quite sure what the "right" thing to do here, though I understand/agree with all the trade-offs already discussed. Worked around it by running the test with the "local" php interpreter which has composer in its PATH, instead.

Production build 0.71.5 2024