public function PermissionsByTermContext::openNodeViewByTitle in Permissions by Term 8
@Then /^I open node view by node title "([^"]*)"$/
Parameters
string $title:
File
- tests/
src/ Behat/ Context/ PermissionsByTermContext.php, line 145
Class
- PermissionsByTermContext
- Class PermissionsByTermContext
Namespace
Drupal\Tests\permissions_by_term\Behat\ContextCode
public function openNodeViewByTitle($title) {
$query = \Drupal::service('database')
->select('node_field_data', 'nfd')
->fields('nfd', [
'nid',
])
->condition('nfd.title', $title);
$this
->visitPath('/node/' . $query
->execute()
->fetchField());
}