function ConfigMapperManagerTest::testHasTranslatable
Same name in other branches
- 9 core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php \Drupal\Tests\config_translation\Unit\ConfigMapperManagerTest::testHasTranslatable()
- 10 core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php \Drupal\Tests\config_translation\Unit\ConfigMapperManagerTest::testHasTranslatable()
- 11.x core/modules/config_translation/tests/src/Unit/ConfigMapperManagerTest.php \Drupal\Tests\config_translation\Unit\ConfigMapperManagerTest::testHasTranslatable()
Tests ConfigMapperManager::hasTranslatable().
@dataProvider providerTestHasTranslatable
Parameters
\Drupal\Core\TypedData\TypedDataInterface $element: The schema element to test.
bool $expected: The expected return value of ConfigMapperManager::hasTranslatable().
File
-
core/
modules/ config_translation/ tests/ src/ Unit/ ConfigMapperManagerTest.php, line 66
Class
- ConfigMapperManagerTest
- Tests the functionality provided by configuration translation mapper manager.
Namespace
Drupal\Tests\config_translation\UnitCode
public function testHasTranslatable(TypedDataInterface $element, $expected) {
$this->typedConfigManager
->expects($this->once())
->method('get')
->with('test')
->will($this->returnValue($element));
$result = $this->configMapperManager
->hasTranslatable('test');
$this->assertSame($expected, $result);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.