You are here

function DrupalTestCase::assertWantedRaw in SimpleTest 5

Same name and namespace in other branches
  1. 6 drupal_test_case.php \DrupalTestCase::assertWantedRaw()

Will trigger a pass if the raw text is found on the loaded page Fail otherwise.

Parameters

string $raw Raw string to look for: @param string $message Message to display. @return boolean True on pass @access public

2 calls to DrupalTestCase::assertWantedRaw()
ImageModuleTest::testImageNode in tests/image_module.test
PageCreationTest::testPageCreation in tests/page_creation.test

File

./drupal_test_case.php, line 405

Class

DrupalTestCase
Test case for typical Drupal tests. Extends WebTestCase for comfortable browser usage but also implements all UnitTestCase methods, I wish WebTestCase would do this.

Code

function assertWantedRaw($raw, $message = "%s") {
  return $this
    ->assertExpectation(new TextExpectation($raw), $this->_browser
    ->getContent(), $message);
}