FieldUIIndentationTest.php

Same filename in other branches
  1. 9 core/modules/field_ui/tests/src/Functional/FieldUIIndentationTest.php
  2. 8.9.x core/modules/field_ui/tests/src/Functional/FieldUIIndentationTest.php
  3. 10 core/modules/field_ui/tests/src/Functional/FieldUIIndentationTest.php

Namespace

Drupal\Tests\field_ui\Functional

File

core/modules/field_ui/tests/src/Functional/FieldUIIndentationTest.php

View source
<?php

declare (strict_types=1);
namespace Drupal\Tests\field_ui\Functional;

use Drupal\Tests\BrowserTestBase;

/**
 * Tests indentation on Field UI.
 *
 * @group field_ui
 */
class FieldUIIndentationTest extends BrowserTestBase {
    
    /**
     * {@inheritdoc}
     */
    protected static $modules = [
        'node',
        'field_ui',
        'field_ui_test',
    ];
    
    /**
     * {@inheritdoc}
     */
    protected $defaultTheme = 'stark';
    
    /**
     * {@inheritdoc}
     */
    protected function setUp() : void {
        parent::setUp();
        // Create a test user.
        $admin_user = $this->drupalCreateUser([
            'access content',
            'administer content types',
            'administer node display',
        ]);
        $this->drupalLogin($admin_user);
        // Create Basic page node type.
        $this->drupalCreateContentType([
            'type' => 'page',
            'name' => 'Basic page',
        ]);
    }
    public function testIndentation() : void {
        $this->drupalGet('admin/structure/types/manage/page/display');
        $this->assertSession()
            ->responseContains('js-indentation indentation');
    }

}

Classes

Title Deprecated Summary
FieldUIIndentationTest Tests indentation on Field UI.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.