Skip to content
Snippets Groups Projects
Commit ac33546d authored by Michael Lee's avatar Michael Lee
Browse files

Upgrading drupal/config_ignore (3.2.0 => 3.3.0)

parent 4ebadb71
No related branches found
No related tags found
1 merge request!87Drupal Module Updates
Showing
with 87 additions and 39 deletions
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "92f52958c86bf4fb794e36c3421465de", "content-hash": "4a6200dbd9ea240498fb22a41c4dafce",
"packages": [ "packages": [
{ {
"name": "asm89/stack-cors", "name": "asm89/stack-cors",
...@@ -2135,20 +2135,20 @@ ...@@ -2135,20 +2135,20 @@
}, },
{ {
"name": "drupal/config_ignore", "name": "drupal/config_ignore",
"version": "3.2.0", "version": "3.3.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://git.drupalcode.org/project/config_ignore.git", "url": "https://git.drupalcode.org/project/config_ignore.git",
"reference": "8.x-3.2" "reference": "8.x-3.3"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://ftp.drupal.org/files/projects/config_ignore-8.x-3.2.zip", "url": "https://ftp.drupal.org/files/projects/config_ignore-8.x-3.3.zip",
"reference": "8.x-3.2", "reference": "8.x-3.3",
"shasum": "00335fc1ddeb4ed93f245dd6963d99b3c084c052" "shasum": "4446811ecb023820a57c227d35c034e0d4363a70"
}, },
"require": { "require": {
"drupal/core": "^8.8 || ^9 || ^10" "drupal/core": "^8.8 || ^9 || ^10 || ^11"
}, },
"require-dev": { "require-dev": {
"drupal/config_filter": "^1.8||^2.2", "drupal/config_filter": "^1.8||^2.2",
...@@ -2157,8 +2157,8 @@ ...@@ -2157,8 +2157,8 @@
"type": "drupal-module", "type": "drupal-module",
"extra": { "extra": {
"drupal": { "drupal": {
"version": "8.x-3.2", "version": "8.x-3.3",
"datestamp": "1705226226", "datestamp": "1713299496",
"security-coverage": { "security-coverage": {
"status": "covered", "status": "covered",
"message": "Covered by Drupal's security advisory policy" "message": "Covered by Drupal's security advisory policy"
...@@ -2167,7 +2167,7 @@ ...@@ -2167,7 +2167,7 @@
}, },
"notification-url": "https://packages.drupal.org/8/downloads", "notification-url": "https://packages.drupal.org/8/downloads",
"license": [ "license": [
"GPL-2.0+" "GPL-2.0-or-later"
], ],
"authors": [ "authors": [
{ {
......
...@@ -2239,21 +2239,21 @@ ...@@ -2239,21 +2239,21 @@
}, },
{ {
"name": "drupal/config_ignore", "name": "drupal/config_ignore",
"version": "3.2.0", "version": "3.3.0",
"version_normalized": "3.2.0.0", "version_normalized": "3.3.0.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://git.drupalcode.org/project/config_ignore.git", "url": "https://git.drupalcode.org/project/config_ignore.git",
"reference": "8.x-3.2" "reference": "8.x-3.3"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://ftp.drupal.org/files/projects/config_ignore-8.x-3.2.zip", "url": "https://ftp.drupal.org/files/projects/config_ignore-8.x-3.3.zip",
"reference": "8.x-3.2", "reference": "8.x-3.3",
"shasum": "00335fc1ddeb4ed93f245dd6963d99b3c084c052" "shasum": "4446811ecb023820a57c227d35c034e0d4363a70"
}, },
"require": { "require": {
"drupal/core": "^8.8 || ^9 || ^10" "drupal/core": "^8.8 || ^9 || ^10 || ^11"
}, },
"require-dev": { "require-dev": {
"drupal/config_filter": "^1.8||^2.2", "drupal/config_filter": "^1.8||^2.2",
...@@ -2262,8 +2262,8 @@ ...@@ -2262,8 +2262,8 @@
"type": "drupal-module", "type": "drupal-module",
"extra": { "extra": {
"drupal": { "drupal": {
"version": "8.x-3.2", "version": "8.x-3.3",
"datestamp": "1705226226", "datestamp": "1713299496",
"security-coverage": { "security-coverage": {
"status": "covered", "status": "covered",
"message": "Covered by Drupal's security advisory policy" "message": "Covered by Drupal's security advisory policy"
...@@ -2273,7 +2273,7 @@ ...@@ -2273,7 +2273,7 @@
"installation-source": "dist", "installation-source": "dist",
"notification-url": "https://packages.drupal.org/8/downloads", "notification-url": "https://packages.drupal.org/8/downloads",
"license": [ "license": [
"GPL-2.0+" "GPL-2.0-or-later"
], ],
"authors": [ "authors": [
{ {
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
'name' => 'osu-asc-webservices/d8-upstream', 'name' => 'osu-asc-webservices/d8-upstream',
'pretty_version' => 'dev-main', 'pretty_version' => 'dev-main',
'version' => 'dev-main', 'version' => 'dev-main',
'reference' => '81b19564eb1adeb564686b2269e82fe176fcbd11', 'reference' => '4ebadb713dc203680a7818fa5fda2eba3ec1ee73',
'type' => 'project', 'type' => 'project',
'install_path' => __DIR__ . '/../../', 'install_path' => __DIR__ . '/../../',
'aliases' => array(), 'aliases' => array(),
...@@ -350,9 +350,9 @@ ...@@ -350,9 +350,9 @@
'dev_requirement' => false, 'dev_requirement' => false,
), ),
'drupal/config_ignore' => array( 'drupal/config_ignore' => array(
'pretty_version' => '3.2.0', 'pretty_version' => '3.3.0',
'version' => '3.2.0.0', 'version' => '3.3.0.0',
'reference' => '8.x-3.2', 'reference' => '8.x-3.3',
'type' => 'drupal-module', 'type' => 'drupal-module',
'install_path' => __DIR__ . '/../../web/modules/config_ignore', 'install_path' => __DIR__ . '/../../web/modules/config_ignore',
'aliases' => array(), 'aliases' => array(),
...@@ -1402,7 +1402,7 @@ ...@@ -1402,7 +1402,7 @@
'osu-asc-webservices/d8-upstream' => array( 'osu-asc-webservices/d8-upstream' => array(
'pretty_version' => 'dev-main', 'pretty_version' => 'dev-main',
'version' => 'dev-main', 'version' => 'dev-main',
'reference' => '81b19564eb1adeb564686b2269e82fe176fcbd11', 'reference' => '4ebadb713dc203680a7818fa5fda2eba3ec1ee73',
'type' => 'project', 'type' => 'project',
'install_path' => __DIR__ . '/../../', 'install_path' => __DIR__ . '/../../',
'aliases' => array(), 'aliases' => array(),
......
anonim
autentificat
behaviour
csslint
ersetztes
Formated
Ignoriertes
Jørgensen
Logat
Lynge
Neues
neues
nord
phplint
Utilizator
Vizitator
webform
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
"issues": "http://drupal.org/project/config_ignore", "issues": "http://drupal.org/project/config_ignore",
"source": "https://git.drupalcode.org/project/config_ignore" "source": "https://git.drupalcode.org/project/config_ignore"
}, },
"license": "GPL-2.0+", "license": "GPL-2.0-or-later",
"minimum-stability": "dev", "minimum-stability": "dev",
"require-dev": { "require-dev": {
"drupal/config_filter": "^1.8||^2.2", "drupal/config_filter": "^1.8||^2.2",
......
name: Config Ignore name: Config Ignore
type: module type: module
description: Ignore certain configuration during imports and exports description: Ignore certain configuration during imports and exports
core_version_requirement: ^8.8 || ^9 || ^10 core_version_requirement: ^8.8 || ^9 || ^10 || ^11
package: Config package: Config
configure: config_ignore.settings configure: config_ignore.settings
# Information added by Drupal.org packaging script on 2024-01-14 # Information added by Drupal.org packaging script on 2024-04-16
version: '8.x-3.2' version: '8.x-3.3'
project: 'config_ignore' project: 'config_ignore'
datestamp: 1705226227 datestamp: 1713299497
...@@ -36,7 +36,14 @@ function config_ignore_update_8301() { ...@@ -36,7 +36,14 @@ function config_ignore_update_8301() {
*/ */
function config_ignore_update_8302() { function config_ignore_update_8302() {
$config = \Drupal::configFactory()->getEditable('config_ignore.settings'); $config = \Drupal::configFactory()->getEditable('config_ignore.settings');
$object = new ConfigIgnoreConfig('simple', $config->get('ignored_config_entities')); $existing = $config->get('mode');
if ($existing) {
if (!in_array($existing, ['simple', 'intermediate', 'advanced'])) {
throw new UnexpectedValueException(sprintf('The mode of the config ignore settings is set but not an expected value: %s', (string) $existing));
}
return;
}
$object = new ConfigIgnoreConfig('simple', $config->get('ignored_config_entities') ?? []);
// Save the config with the mode set and the settings sorted. // Save the config with the mode set and the settings sorted.
$config->set('mode', 'simple'); $config->set('mode', 'simple');
$config->set('ignored_config_entities', $object->getFormated('simple')); $config->set('ignored_config_entities', $object->getFormated('simple'));
......
...@@ -87,9 +87,10 @@ public function invalidateTags(array $tags) { ...@@ -87,9 +87,10 @@ public function invalidateTags(array $tags) {
* {@inheritdoc} * {@inheritdoc}
*/ */
public static function getSubscribedEvents(): array { public static function getSubscribedEvents(): array {
// phpcs:disable Drupal.Arrays.Array.LongLineDeclaration
return [ return [
ConfigEvents::STORAGE_TRANSFORM_IMPORT => ['onImportTransform', Settings::get('config_ignore_import_priority', 0)], ConfigEvents::STORAGE_TRANSFORM_IMPORT => ['onImportTransform', Settings::get('config_ignore_import_priority', -100)],
ConfigEvents::STORAGE_TRANSFORM_EXPORT => ['onExportTransform', Settings::get('config_ignore_export_priority', 0)], ConfigEvents::STORAGE_TRANSFORM_EXPORT => ['onExportTransform', Settings::get('config_ignore_export_priority', -100)],
]; ];
} }
...@@ -133,6 +134,10 @@ protected function transformStorage(StorageInterface $transformation_storage, St ...@@ -133,6 +134,10 @@ protected function transformStorage(StorageInterface $transformation_storage, St
// Get the config ignore settings form the transformation storage. // Get the config ignore settings form the transformation storage.
$transformation_storage = $transformation_storage->createCollection(StorageInterface::DEFAULT_COLLECTION); $transformation_storage = $transformation_storage->createCollection(StorageInterface::DEFAULT_COLLECTION);
if (empty($transformation_storage->listAll())) {
// Skip if the transformation storage is empty in the default collection.
return;
}
if ($transformation_storage->exists('config_ignore.settings')) { if ($transformation_storage->exists('config_ignore.settings')) {
try { try {
// This can be used to hook into config ignore via an event subscriber // This can be used to hook into config ignore via an event subscriber
......
...@@ -6,7 +6,7 @@ hidden: true ...@@ -6,7 +6,7 @@ hidden: true
dependencies: dependencies:
- config_ignore - config_ignore
# Information added by Drupal.org packaging script on 2024-01-14 # Information added by Drupal.org packaging script on 2024-04-16
version: '8.x-3.2' version: '8.x-3.3'
project: 'config_ignore' project: 'config_ignore'
datestamp: 1705226227 datestamp: 1713299497
...@@ -34,13 +34,30 @@ public function testSettingsForm() { ...@@ -34,13 +34,30 @@ public function testSettingsForm() {
]; ];
$this->drupalGet('admin/config/development/configuration/ignore'); $this->drupalGet('admin/config/development/configuration/ignore');
$this->submitForm($edit, $this->t('Save configuration')); $this->submitForm($edit, (string) $this->t('Save configuration'));
$settings = $this->config('config_ignore.settings')->get('ignored_config_entities'); $settings = $this->config('config_ignore.settings')->get('ignored_config_entities');
$this->assertEquals(['config.test_01', 'config.test_02'], $settings); $this->assertEquals(['config.test_01', 'config.test_02'], $settings);
} }
/**
* Verify that the config sync form loads after ignore settings are saved.
*
* Also installs core field module.
*/
public function testSynchronizeForm() {
$this->container->get('module_installer')->install(['field']);
$this->drupalLogin($this->drupalCreateUser(['import configuration', 'synchronize configuration']));
$edit = [
'ignored_config_entities' => "system.site" . "\r\n" . "'system.menu.*'",
];
$this->drupalGet('admin/config/development/configuration/ignore');
$this->submitForm($edit, (string) $this->t('Save configuration'));
$this->drupalGet('admin/config/development/configuration');
$this->assertSession()->statusCodeEquals(200);
}
/** /**
* Verify that config can get ignored. * Verify that config can get ignored.
*/ */
......
...@@ -104,7 +104,7 @@ public function testExport(string $mode, array $patterns, array $active, array $ ...@@ -104,7 +104,7 @@ public function testExport(string $mode, array $patterns, array $active, array $
* choice, and we implemented the more strict definition of "ignore". * choice, and we implemented the more strict definition of "ignore".
* A commented out scenario for the more "lenient" option remained in the list * A commented out scenario for the more "lenient" option remained in the list
* So that we could assert it when implementing a feature that allows one to * So that we could assert it when implementing a feature that allows one to
* configure the behaviour. It is configured differntly than originally * configure the behaviour. It is configured differently than originally
* anticipated. So this method sets up the config in the new way to cater to * anticipated. So this method sets up the config in the new way to cater to
* the test scenario. * the test scenario.
* *
......
...@@ -11,6 +11,8 @@ ...@@ -11,6 +11,8 @@
/** /**
* Test the schema. * Test the schema.
*
* @group config_ignore
*/ */
class IgnoreSchemaTest extends KernelTestBase { class IgnoreSchemaTest extends KernelTestBase {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment