Skip to content
Snippets Groups Projects
Commit aa649dc9 authored by catch's avatar catch
Browse files

Issue #3321634 by Spokje, andypost: Remove legacy experimental:true and its...

Issue #3321634 by Spokje, andypost: Remove legacy experimental:true and its deprecation and test-files

(cherry picked from commit 5c254c67)
parent 1fd6c15a
No related branches found
No related tags found
26 merge requests!11185Issue #3477324 by andypost, alexpott: Fix usage of str_getcsv() and fgetcsv() for PHP 8.4,!10602Issue #3438769 by vinmayiswamy, antonnavi, michelle, amateescu: Sub workspace does not clear,!10301Issue #3469309 by mstrelan, smustgrave, moshe weitzman: Use one-time login...,!10187Issue #3487488 by dakwamine: ExtensionMimeTypeGuesser::guessMimeType must support file names with "0" (zero) like foo.0.zip,!9944Issue #3483353: Consider making the createCopy config action optionally fail...,!9929Issue #3445469 by pooja_sharma, smustgrave: Add additional test coverage for...,!9787Resolve issue 3479427 - bootstrap barrio issue under Windows,!9742Issue #3463908 by catch, quietone: Split OptionsFieldUiTest into two,!9526Issue #3458177 by mondrake, catch, quietone, godotislate, longwave, larowlan,...,!8738Issue #3424162 by camilledavis, dineshkumarbollu, smustgrave: Claro...,!8704Make greek characters available in ckeditor5,!8597Draft: Issue #3442259 by catch, quietone, dww: Reduce time of Migrate Upgrade tests...,!8533Issue #3446962 by kim.pepper: Remove incorrectly added...,!8517Issue #3443748 by NexusNovaz, smustgrave: Testcase creates false positive,!8325Update file Sort.php,!8095Expose document root on install,!7930Resolve #3427374 "Taxonomytid viewsargumentdefault plugin",!7627Issue #3439440 by nicxvan, Binoli Lalani, longwave: Remove country support from DateFormatter,!7445Issue #3440169: When using drupalGet(), provide an associative array for $headers,!7401#3271894 Fix documented StreamWrapperInterface return types for realpath() and dirname(),!7384Add constraints to system.advisories,!7078Issue #3320569 by Spokje, mondrake, smustgrave, longwave, quietone, Lendude,...,!6622Issue #2559833 by piggito, mohit_aghera, larowlan, guptahemant, vakulrai,...,!6502Draft: Resolve #2938524 "Plach testing issue",!38582585169-10.1.x,!3226Issue #2987537: Custom menu link entity type should not declare "bundle" entity key
Pipeline #110328 passed with warnings
Pipeline: drupal

#110333

    ......@@ -223,15 +223,6 @@ public function __wakeup() {
    * TRUE if an extension is marked as experimental, FALSE otherwise.
    */
    public function isExperimental(): bool {
    // Currently, this function checks for both the key/value pairs
    // 'experimental: true' and 'lifecycle: experimental' to determine if an
    // extension is marked as experimental.
    // @todo Remove the deprecation check for 'experimental: true' as part of
    // https://www.drupal.org/node/3321634
    if (isset($this->info['experimental']) && $this->info['experimental']) {
    @trigger_error('The key-value pair "experimental: true" is deprecated in drupal:10.1.0 and will be removed before drupal:11.0.0. Use the key-value pair "lifecycle: experimental" instead. See https://www.drupal.org/node/3263585', E_USER_DEPRECATED);
    return TRUE;
    }
    return (isset($this->info[ExtensionLifecycle::LIFECYCLE_IDENTIFIER])
    && $this->info[ExtensionLifecycle::LIFECYCLE_IDENTIFIER] === ExtensionLifecycle::EXPERIMENTAL);
    }
    ......
    ......@@ -158,14 +158,6 @@ function system_requirements($phase) {
    $obsolete_extensions[$theme] = ['name' => $info['name'], 'lifecycle_link' => $info['lifecycle_link']];
    }
    }
    // Currently, we check for both the key/value pairs 'experimental: true'
    // and 'lifecycle: experimental' to determine if an extension is marked as
    // experimental.
    // @todo Remove the check for 'experimental: true' as part of
    // https://www.drupal.org/node/3250342
    if (isset($data->info['experimental']) && $data->info['experimental']) {
    $experimental_themes[$theme] = $data->info['name'];
    }
    }
    // Warn if any experimental themes are installed.
    ......
    ......@@ -11,11 +11,8 @@
    * Implements hook_system_info_alter().
    */
    function theme_page_test_system_info_alter(&$info, Extension $file, $type) {
    // Make sure that all themes are visible on the Appearance form, except for
    // the legacy_experimental_theme_test theme.
    // @todo Remove the exception for this theme in
    // https://www.drupal.org/node/3321634
    if ($type === 'theme' && $info['name'] !== 'Legacy experimental test') {
    // Make sure that all themes are visible on the Appearance form.
    if ($type === 'theme') {
    unset($info['hidden']);
    }
    }
    name: 'Legacy experimental dependency test'
    type: theme
    description: 'Legacy experimental dependency test theme.'
    version: VERSION
    base theme: legacy_experimental_theme_test
    name: 'Legacy experimental test'
    type: theme
    description: 'Legacy experimental test theme.'
    version: VERSION
    base theme: false
    experimental: true
    hidden: true
    <?php
    namespace Drupal\KernelTests\Core\Extension;
    use Drupal\KernelTests\KernelTestBase;
    /**
    * Tests deprecated update.inc functions.
    *
    * @group legacy
    * @group extension
    *
    * @todo Remove this and all its test themes in
    * https://www.drupal.org/node/3321634
    */
    class ExperimentalDeprecationTest extends KernelTestBase {
    /**
    * Tests \Drupal\Core\Extension\Extension::isExperimental deprecation.
    */
    public function testLegacyIsExperimental(): void {
    /** @var \Drupal\Core\Extension\ThemeInstallerInterface $theme_installer */
    $theme_installer = \Drupal::service('theme_installer');
    $theme_installer->install(['legacy_experimental_theme_test']);
    /** @var \Drupal\Core\Extension\ThemeHandler $theme_handler */
    $theme_handler = $this->container->get('theme_handler');
    $theme = $theme_handler->getTheme('legacy_experimental_theme_test');
    $this->expectDeprecation('The key-value pair "experimental: true" is deprecated in drupal:10.1.0 and will be removed before drupal:11.0.0. Use the key-value pair "lifecycle: experimental" instead. See https://www.drupal.org/node/3263585');
    $this->assertTrue($theme->isExperimental());
    }
    }
    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