/**
 * @Then the :selector numeric input should have the value :expected
 */
public function assertNumericInputHasValue($selector, $expected) {
  $page = $this->getSession()->getPage();
  $element = $page->find('css', $selector);
  if (!$element) {
    throw new ExpectationException(sprintf('The "%s" element wasn\'t found', $element), $this->getSession()
      ->getDriver());
  }
  $actual = $element->getAttribute('value');
  if ($actual != $expected) {
    throw new ExpectationException(sprintf('The "%s" element was set to %d instead of %d.', $element, $actual, $expected), $this->getSession()
      ->getDriver());
  }
}
Tags
/**
 * @Then the :button CKeditor button should be :state
 */
public function assertCKEditorButtonState($button, $state) {
  $page = $this->getSession()->getPage();
  $locator = '//li[@data-drupal-ckeditor-button-name= "' . $button. '"]';
  $selectElement = $page->find('xpath', $locator);
  if (!$selectElement) {
    throw new ExpectationException(sprintf('The CKeditor button "%s" wasn\'t found', $button), $this->getSession()
      ->getDriver());
  }
  $enabled = $page->find('xpath', $locator. '/ancestor::ul[contains(@class,\'ckeditor-active-toolbar-configuration\')]');
  $enabled = $enabled ? 'enabled' : 'disabled';
  if ($enabled != $state) {
    throw new ExpectationException(sprintf('The CKeditor button "%s" was %s', $button, $enabled), $this->getSession()
      ->getDriver());
  }
}

If a page title isn't appearing, check whether the metatags module is installed - it might be getting the title from a custom field that's it's expecting to be in the node type: /admin/config/search/metatag.

Requires the following to be added to settings.php (example below uses /beta).

if(isset($GLOBALS['request'])) {
  $scriptName = $GLOBALS['request']->server->get('SCRIPT_NAME');
  $scriptName = preg_match('#^/beta/#', $scriptName) ? $scriptName : "/beta$scriptName";
  $GLOBALS['request']->server->set('SCRIPT_NAME', $scriptName);
}
 

What's the point to having a Virtual Private Server?

Until now, I've focused mainly on the utility it provides - having my own mail server means I never need to send out "My email address has changed" messages. Using the virtual hosts for my various projects allows me to help those causes. But to my way of thinking, there are things much more important than convenience or individual causes (worthy though I think they are). The most important thing in all the world must surely be the purpose for which we are here. If you and I were made for something or someone and we never discover that; if we die having wasted our one opportunity, wouldn't that be a terrible loss?

I'm going to lay my cards on the table and say, straight out, that I'm a Christian. I believe we were made by God in order to know and be known by Him. I believe the greatest security, peace, joy, comfort and hope we get in life comes from Him. The question for me then is "How do I put that out there in a way that's helpful to you?"

Until now, my website has been a bit useless in that regard. I've occasionally posted sermons, but sermons are for Christians. I'm going to have a go at putting some more diverse content on my site - some technical stuff related to work that might be useful to others, thoughts on current events and more, and I'm going to try opening up comments (moderated if necessary). Let's see if I can manage to be "winsome", as my pastor likes to say.