function TourTest::getTourTips
Gets tour tips from the JavaScript drupalSettings variable.
Return value
array A list of tips and their data.
File
-
core/
modules/ tour/ tests/ src/ Functional/ TourTest.php, line 243
Class
- TourTest
- Tests the functionality of tour tips.
Namespace
Drupal\Tests\tour\FunctionalCode
protected function getTourTips() {
$tips = [];
$drupalSettings = $this->getDrupalSettings();
if (isset($drupalSettings['_tour_internal'])) {
foreach ($drupalSettings['_tour_internal'] as $tip) {
$tips[] = $tip;
}
}
return $tips;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.