Problem/Motivation

The metatag.settings looks like this:

entity_type_groups:
  node:
    article:
      my_group: my_group

The current schema does not apply to this.

Proposed resolution

Adjust the schema definition.

Comments

chr.fritsch created an issue. See original summary.

chr.fritsch’s picture

Status: Active » Needs review
StatusFileSize
new690 bytes

Here is a patch

damienmckenna’s picture

Thanks for working that out, I really appreciate it.

Are there any core requirements in order to use "config_object"?

chr.fritsch’s picture

Without using "config_object" I got metatag.settings:_core missing schema, metatag.settings:langcode missing schema issues.

damienmckenna’s picture

Out of interest, how did you trigger this problem?

chr.fritsch’s picture

I am currently working on this PR for the Thunder distribution (https://github.com/BurdaMagazinOrg/thunder-distribution/pull/684).

And we have the Drupal\Tests\thunder\Functional\InstalledConfigurationTest::testInstalledConfiguration test in Thunder that is quite strict. So it found that problem here: https://travis-ci.org/BurdaMagazinOrg/thunder-distribution/jobs/517837256

idebr’s picture

StatusFileSize
new1.26 KB
new1.93 KB

Added a KernelTest to show the current config schema is incomplete.

idebr’s picture

+++ b/tests/src/Kernel/MetatagSettingsTest.php
@@ -1,9 +1,51 @@
+    $config = \Drupal::configFactory()->getEditable('metatag.settings');    $i = 0;

$i = 0 is a leftover debugging statement, feel free to remove :)

damienmckenna’s picture

@idebr: Oh! Tests! Thanks!

BTW Did you forget something with the patch? The file tests/src/Kernel/MetatagSettingsTest.php doesn't currently exist in the codebase so the patch doesn't apply.

idebr’s picture

StatusFileSize
new1.2 KB
new1.87 KB

Let's see if this patch does a better job at applying correctly to 8.x-1.x.

The last submitted patch, 10: 3046976-10-test-only.patch, failed testing. View results

idebr’s picture

StatusFileSize
new760 bytes
new978 bytes
new1.63 KB

Removed some unused code from the new test.

The last submitted patch, 12: 3046976-12-test-only.patch, failed testing. View results

  • DamienMcKenna committed d6b9404 on 8.x-1.x authored by idebr
    Issue #3046976 by idebr, chr.fritsch: Schema for entity_type_groups is...
damienmckenna’s picture

Status: Needs review » Fixed
Parent issue: » #2996500: Plan for Metatag 8.x-1.10

Committed. Thanks!

Status: Fixed » Closed (fixed)

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