protected function TextEditorTest::setBodyFormat in The CodeMirror Editor 8
Sets text format for body field.
Parameters
string $format: The format.
1 call to TextEditorTest::setBodyFormat()
- TextEditorTest::testTextEditor in tests/
src/ FunctionalJavascript/ TextEditorTest.php - Test callback.
File
- tests/
src/ FunctionalJavascript/ TextEditorTest.php, line 150
Class
- TextEditorTest
- Tests the CodeMirror text editor.
Namespace
Drupal\Tests\codemirror_editor\FunctionalJavascriptCode
protected function setBodyFormat($format) {
$this
->getSession()
->getPage()
->find('xpath', '//select[@name = "body[0][format]"]')
->selectOption($format);
sleep(1);
}