function UserViewsDataTest::testUserPasswordFieldNotAvailableToViews
Same name in other branches
- 10 core/modules/user/tests/src/Kernel/Views/UserViewsDataTest.php \Drupal\Tests\user\Kernel\Views\UserViewsDataTest::testUserPasswordFieldNotAvailableToViews()
- 11.x core/modules/user/tests/src/Kernel/Views/UserViewsDataTest.php \Drupal\Tests\user\Kernel\Views\UserViewsDataTest::testUserPasswordFieldNotAvailableToViews()
Tests if user views data object doesn't contain pass field.
File
-
core/
modules/ user/ tests/ src/ Kernel/ Views/ UserViewsDataTest.php, line 51
Class
- UserViewsDataTest
- Contains tests related to the views data for the user entity type.
Namespace
Drupal\Tests\user\Kernel\ViewsCode
public function testUserPasswordFieldNotAvailableToViews() {
$field_definitions = $this->entityFieldManager
->getBaseFieldDefinitions('user');
$this->assertArrayHasKey('pass', $field_definitions);
$this->assertArrayNotHasKey('pass', $this->viewsData
->get('users_field_data'));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.