protected function ConfigTranslationUiTest::renderContextualLinks in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/config_translation/src/Tests/ConfigTranslationUiTest.php \Drupal\config_translation\Tests\ConfigTranslationUiTest::renderContextualLinks()
Get server-rendered contextual links for the given contextual link ids.
Parameters
array $ids: An array of contextual link ids.
string $current_path: The Drupal path for the page for which the contextual links are rendered.
Return value
string The response body.
1 call to ConfigTranslationUiTest::renderContextualLinks()
- ConfigTranslationUiTest::testViewsTranslationUI in core/
modules/ config_translation/ src/ Tests/ ConfigTranslationUiTest.php - Tests the views translation interface.
File
- core/
modules/ config_translation/ src/ Tests/ ConfigTranslationUiTest.php, line 1026 - Contains \Drupal\config_translation\Tests\ConfigTranslationUiTest.
Class
- ConfigTranslationUiTest
- Translate settings and entities to various languages.
Namespace
Drupal\config_translation\TestsCode
protected function renderContextualLinks($ids, $current_path) {
$post = array();
for ($i = 0; $i < count($ids); $i++) {
$post['ids[' . $i . ']'] = $ids[$i];
}
return $this
->drupalPostWithFormat('contextual/render', 'json', $post, array(
'query' => array(
'destination' => $current_path,
),
));
}