Don't rely on Behat/Selenium returning 'value' for textarea

Technically a textarea DOM node doesn't have a 'value' attribute,
but rather a HTML content. This used to work, but likely broke either
by updated browser handling or updated selenium logic.
Fixes "Scenario: I can edit title and content and see the changes on draft"
This commit is contained in:
Ingo Schommer 2013-11-22 20:05:17 +01:00
parent 556090ccfa
commit 8245125349

View File

@ -92,7 +92,7 @@ class CmsFormsContext extends BehatContext {
$element = $page->findField($locator);
assertNotNull($element, sprintf('HTML field "%s" not found', $locator));
$actual = $element->getAttribute('value');
$actual = $element->getHTML();
$regex = '/'.preg_quote($html, '/').'/ui';
if (!preg_match($regex, $actual)) {
$message = sprintf(