387e6b235bb0a34416d3e42cf444e284431a9d81
[yaffs-website] / web / core / modules / field_layout / tests / src / Kernel / FieldLayoutUninstallTest.php
1 <?php
2
3 namespace Drupal\Tests\field_layout\Kernel;
4
5 use Drupal\Tests\layout_builder\Kernel\LayoutBuilderCompatibilityTestBase;
6
7 /**
8  * @group field_layout
9  */
10 class FieldLayoutUninstallTest extends LayoutBuilderCompatibilityTestBase {
11
12   /**
13    * Ensures field layout can be uninstalled with layout builder enabled.
14    */
15   public function testFieldLayoutUninstall() {
16     // Setup user schema so user hook uninstall hook doesn't break.
17     $this->installSchema('user', 'users_data');
18
19     // Setup layout builder and same displays.
20     $this->installLayoutBuilder();
21
22     // Ensure install hook can handle displays without a layout.
23     $this->container->get('module_installer')->install(['field_layout']);
24
25     // Ensure uninstall hook can handle displays without a layout.
26     $this->container->get('module_installer')->uninstall(['field_layout']);
27   }
28
29 }