Problem/Motivation

For the removal process we need to go through manual testing. I've documented a set of steps. I will use these to test color. See: https://www.drupal.org/project/project_composer/issues/3299191#comment-1...

Steps to reproduce

n.a.

Proposed resolution

Run an adjusted test script for color.

Remaining tasks

Do the testing

User interface changes

n.a.

API changes

n.a.

Data model changes

n.a.

Release notes snippet

n.a.

Comments

bbrala created an issue. See original summary.

bbrala’s picture

hmm, those wont do, looking for a theme.

spokje’s picture

Would this help:

https://git.drupalcode.org/search?group_id=2&repository_ref=&scope=blobs...

Projects with color.inc, without references to bartik and without array in them, which would indicate D7 stuff.

longwave’s picture

https://www.drupal.org/project/honey looks like a good test candidate. It is a simple theme written as an example for the user guide, and contains a bunch of color module configuration options.

bbrala’s picture

Thanks guys, will look at those. Found another one which just adds a color picker to the theme settings that might work.

Will continue tonight. I did notice the parent issue might need a rebate since it doesn't run on php8 (when updating to d10) because of laminas. Think this means an old composer.json but will double check that also tonight.

spokje’s picture

did notice the parent issue might need a rebate since it doesn't run on php8 (when updating to d10) because of laminas. Think this means an old composer.json but will double check that also tonight.

Hmm, parent (#3270899: Remove Color module from core) is on 10.0.x, so PHP 8.1, not sure if you've used PHP 8.0 for your tests?

Anyway: Parent did have a merge-conflict, that should be fixed now.

bbrala’s picture

Honey installs and works when combined with:

composer require mglaman/composer-drupal-lenient
composer config --merge --json extra.drupal-lenient.allowed-list '["drupal/honey"]'

Then replace ^9 with ^9 || ^10 in the honey.info.yml and it installs and loads. I'll go through these steps cleanly and document. The color picker does show in d10 at least with the contrib.

Added longwave and spokje to credits for looking for possible contrib modules to use to test.

bbrala’s picture

> Hmm, parent (#3270899: [PP-1] Remove Color module from core) is on 10.0.x, so PHP 8.1, not sure if you've used PHP 8.0 for your tests?

I use 8.1, but it seems the problem was something else. It couldn't resolve to a good set of dependencies, which kept laminas back and therefor mentioned the php version as a possible reason. So thats a false alarm.

The whole depenency resolution information of composer is a bit confusing smoethings.

bbrala’s picture

This is the steps i did. All seemed fine. But after applying the patch in the parent issue it is missing some css. But, the color picker is working as expected.

Below what i did:
Manually test for upgrading from the core module to the contrib module.

Install Drupal 9.3 on a machine with composer.

  1. composer create-project "drupal/recommended-project:9.3.*" drupal-module-color
  2. Move your shell into the directory cd drupal-module-color
  3. Enable development settings cp web/sites/example.settings.local.php web/sites/settings.local.php
  4. Add Drush with composer require drush/drush because life is better with Drush :)
  5. Run the default installer with Umami so we have some content vendor/bin/drush si demo_umami
  6. Enable ignoring drupal version requirements with
    composer config minimum-stability dev
    composer require mglaman/composer-drupal-lenient
    composer config --merge --json extra.drupal-lenient.allowed-list '["drupal/honey"]'

Enable and configure the module

  1. Enable color: vendor/bin/drush en color --yes
  2. Export the current config: vendor/bin/drush cex --yes
  3. Install honey and enable
    composer require drupal/honey
    vendor/bin/drush theme:enable honey

    Then set as default theme

  4. Edit honey.info.yml to allow installation on drupal 10 core_version:requirement: ^9 || ^10

Test the module (9.3)

  1. Go to honey theme settings and select some colors: http://drupal-module-color.web.swisdev.nl/en/admin/appearance/settings/honey
  2. Test if changes are visible on the frontend

Now we are going to upgrade to Drupal 9.4. Easy as ever.

  1. Update composer dependencies to 9.4
    composer require drupal/core-composer-scaffold:9.4.x-dev --no-update
    composer require drupal/core-project-message:9.4.x-dev --no-update
    composer require drupal/core-recommended:9.4.x-dev --no-update
  2. Run composer update
  3. Run vendor/bin/drush updb.

Test module again (9.4)

  1. Go to honey theme settings and select some colors: http://drupal-module-color.web.swisdev.nl/en/admin/appearance/settings/honey
  2. Test if changes are visible on the frontend

Update to contrib

  1. Color has a 9.4 and 10 version in contrib. Lets include that.
  2. Run composer require drupal/color to require the new contrib module

Test module again (9.4)

  1. Go to honey theme settings and select some colors: http://drupal-module-color.web.swisdev.nl/en/admin/appearance/settings/honey

Now we are going to upgrade to Drupal 10. Easy as ever.

  1. Update composer dependencies to 10
    composer require drupal/core-composer-scaffold:10.0.x-dev --no-update
    composer require drupal/core-project-message:10.0.x-dev --no-update
    composer require drupal/core-recommended:10.0.x-dev --no-update
  2. Run composer update
  3. Run vendor/bin/drush updb.
  4. Run vendor/bin/drush cr

Test module again

  1. Go to honey theme settings and select some colors: http://drupal-module-color.web.swisdev.nl/en/admin/appearance/settings/honey
  2. Test if changes are visible on the frontend

Success!

You've now successfully tested the module. For other modules this might be more steps in regards to the testing steps since they have more moving parts.

bbrala’s picture

Status: Active » Needs review

Ok the problem in 10 was the weird patch not applying normally.

I did a core install with the branch of the parent patch, installed honey with lenient. There were no color options. Installed and enabled contrib color, and everything worked as expected.

I declare this verified.

andypost’s picture

I think I need to merge few commits into contrib color module as there was changes in core, but can't find the guide how to upgrade this split

longwave’s picture

Status: Needs review » Reviewed & tested by the community

RTBC. Thanks for the great set of test steps. I have replicated the manual test, poked around in the database for paths, and clicked around my test site and confirm that everything continues to work as expected in Honey theme when Color module has been removed from core and replaced with the contrib version.

@andypost I think that should be done outside of this issue, this is for manual testing only?

andypost’s picture

sure ++rtbc (I just lost in issues)

longwave’s picture

@andypost Opened #3302976: Port remaining changes from core to track that

xjm’s picture

Status: Reviewed & tested by the community » Fixed

Well done, thanks everyone!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.