Validate config schema compliance of Demo Umami and Minimal profiles, just like we do for Standard

Created on 26 July 2023, over 1 year ago
Updated 27 July 2023, over 1 year ago

Problem/Motivation

\Drupal\Tests\standard\Functional\StandardTest::testStandard() validates all installed config for config schema compliance.

Umami should do the same.

Steps to reproduce

N/A

Proposed resolution

Copy test coverage from the Standard profile's test coverage.

Remaining tasks

  1. Copy test coverage from the Standard profile's test coverage.
  2. Fix failures caused by config schema violations in Demo Umami's config — given the problems surfaced at 📌 KernelTestBase::$strictConfigSchema = TRUE and BrowserTestBase::$strictConfigSchema = TRUE do not actually strictly validate Fixed , we know for sure there are problems.

User interface changes

None.

API changes

None.

Data model changes

None.

Release notes snippet

None.

📌 Task
Status

Fixed

Version

11.0 🔥

Component
Umami 

Last updated about 1 month ago

Created by

🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

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

Comments & Activities

  • Issue created by @wim leers
  • Open on Drupal.org →
    Environment: PHP 8.2 & MySQL 8
    last update over 1 year ago
    Not currently mergeable.
  • @wim-leers opened merge request.
  • last update over 1 year ago
    118 pass
  • last update over 1 year ago
    112 pass, 1 fail
  • Assigned to wim leers
  • Status changed to Needs review over 1 year ago
  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    I expect this to fail like so:

    1) Drupal\Tests\demo_umami\Functional\DemoUmamiProfileTest::testConfig
    Failed asserting that two arrays are identical.
    --- Expected
    +++ Actual
    @@ @@
    -Array &0 ()
    +Array &0 (
    +    0 => 'The current CKEditor 5 build requires the following elements and attributes: <br><code><br> <p> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id> <* dir="ltr rtl" lang> <cite> <dl> <dt> <dd> <a hreflang href> <blockquote cite> <ul type> <ol type start reversed> <img src alt data-entity-type data-entity-uuid data-align data-caption width height> <drupal-media data-view-mode title data-entity-type data-entity-uuid alt data-caption data-align> <strong> <em> <li>


    The following elements are not supported:
    <img loading>'
    + 1 => 'The current CKEditor 5 build requires the following elements and attributes:
    <br> <p> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id> <* dir="ltr rtl" lang> <cite> <dl> <dt> <dd> <a hreflang href> <blockquote cite> <ul type> <ol type start reversed> <img src alt data-entity-type data-entity-uuid data-align data-caption width height> <drupal-media data-view-mode title data-entity-type data-entity-uuid alt data-caption data-align> <strong> <em> <li>
    The following elements are missing:
    <ol reversed>'
    + 2 => 'Configuration for the enabled plugin "List" (ckeditor5_list) is missing.'
    + 3 => 'Configuration for the enabled plugin "Media" (media_media) is missing.'
    +)

  • last update over 1 year ago
    112 pass, 1 fail
  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    Now expecting

    1) Drupal\Tests\demo_umami\Functional\DemoUmamiProfileTest::testConfig
    Failed asserting that two arrays are identical.
    --- Expected
    +++ Actual
    @@ @@
    -Array &0 ()
    +Array &0 (
    +    0 => 'The current CKEditor 5 build requires the following elements and attributes: <br> <p> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id> <* dir="ltr rtl" lang> <cite> <dl> <dt> <dd> <a hreflang href> <blockquote cite> <ul type> <ol type start> <img src alt data-entity-type data-entity-uuid data-align data-caption width height> <drupal-media data-view-mode title data-entity-type data-entity-uuid alt data-caption data-align> <strong> <em> <li>The following elements are not supported: <img loading>'
    +)
    

    Root cause: #3247795: Add text filter plugin to support and remove it from editor_file_reference wanted to allow users of Basic HTML to override the loading attribute on <img>, but didn't correctly upgrade the CKEditor 5 settings to actually allow it.

  • last update over 1 year ago
    118 pass
  • Issue was unassigned.
  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    That should be green!

  • Status changed to Needs work over 1 year ago
  • 🇧🇪Belgium borisson_ Mechelen, 🇧🇪

    Great, let's change the drupalci.yml back to the default.

  • last update over 1 year ago
    29,879 pass
  • Status changed to Needs review over 1 year ago
  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    Did that, and also applied it to the install profile as you requested in Slack. Note that for Minimal, I did not include the CKEditor 5 validation logic because Minimal has no configuration that enables CKEditor 5.

  • Status changed to RTBC over 1 year ago
  • 🇧🇪Belgium borisson_ Mechelen, 🇧🇪

    Great, this will hopefully make sure that every config we have in core that comes with an install profile is compliant with the schema's that underpin it. These tests will probably break when we increase the validation of the config schema's but this is a great way to keep those schema's in check.

  • 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺

    Exactly, that's the goal! 😊

  • First commit to issue fork.
  • last update over 1 year ago
    29,882 pass
  • last update over 1 year ago
    29,885 pass
  • 🇫🇮Finland lauriii Finland

    Committed 39cf4d2 and pushed to 11.x. Thanks!

    • lauriii committed 39cf4d22 on 11.x
      Issue #3377055 by Wim Leers, borisson_: Validate config schema...
  • Status changed to Fixed over 1 year ago
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024