You are here

public function GeneralTest::testSubmitEmptyTextarea in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/behat/mink/driver-testsuite/tests/Form/GeneralTest.php \Behat\Mink\Tests\Driver\Form\GeneralTest::testSubmitEmptyTextarea()

File

vendor/behat/mink/driver-testsuite/tests/Form/GeneralTest.php, line 293

Class

GeneralTest

Namespace

Behat\Mink\Tests\Driver\Form

Code

public function testSubmitEmptyTextarea() {
  $this
    ->getSession()
    ->visit($this
    ->pathTo('/empty_textarea.html'));
  $page = $this
    ->getSession()
    ->getPage();
  $page
    ->pressButton('Save');
  $toSearch = array(
    "'textarea' = '',",
    "'submit' = 'Save',",
    'no file',
  );
  $pageContent = $page
    ->getContent();
  foreach ($toSearch as $searchString) {
    $this
      ->assertContains($searchString, $pageContent);
  }
}