function FieldTest::getBaseFieldStorage
Same name in other branches
- 9 core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php \Drupal\Tests\views\Unit\Plugin\field\FieldTest::getBaseFieldStorage()
- 8.9.x core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php \Drupal\Tests\views\Unit\Plugin\field\FieldTest::getBaseFieldStorage()
- 10 core/modules/views/tests/src/Unit/Plugin/field/FieldTest.php \Drupal\Tests\views\Unit\Plugin\field\FieldTest::getBaseFieldStorage()
Returns a mocked base field storage object.
Return value
\Drupal\Core\Field\FieldStorageDefinitionInterface|\PHPUnit\Framework\MockObject\MockObject
7 calls to FieldTest::getBaseFieldStorage()
- FieldTest::testAccess in core/
modules/ views/ tests/ src/ Unit/ Plugin/ field/ FieldTest.php - @covers ::access
- FieldTest::testCalculateDependenciesWithBaseField in core/
modules/ views/ tests/ src/ Unit/ Plugin/ field/ FieldTest.php - @covers ::calculateDependencies
- FieldTest::testClickSortWithBaseField in core/
modules/ views/ tests/ src/ Unit/ Plugin/ field/ FieldTest.php - @dataProvider providerSortOrders
- FieldTest::testDefineOptionsWithDefaultFormatterOnFieldDefinition in core/
modules/ views/ tests/ src/ Unit/ Plugin/ field/ FieldTest.php - @covers ::defineOptions
- FieldTest::testDefineOptionsWithDefaultFormatterOnFieldType in core/
modules/ views/ tests/ src/ Unit/ Plugin/ field/ FieldTest.php - @covers ::defineOptions
File
-
core/
modules/ views/ tests/ src/ Unit/ Plugin/ field/ FieldTest.php, line 671
Class
- FieldTest
- @coversDefaultClass \Drupal\views\Plugin\views\field\EntityField @group views
Namespace
Drupal\Tests\views\Unit\Plugin\fieldCode
protected function getBaseFieldStorage() {
$title_storage = $this->createMock('Drupal\\Core\\Field\\FieldStorageDefinitionInterface');
$title_storage->expects($this->any())
->method('getColumns')
->willReturn([
'value' => [
'type' => 'varchar',
],
]);
$title_storage->expects($this->any())
->method('getSettings')
->willReturn([]);
$title_storage->expects($this->any())
->method('getConstraints')
->willReturn([]);
return $title_storage;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.