Search for assert

  1. Search 9.5.x for assert
  2. Search 8.9.x for assert
  3. Search 10.3.x for assert
  4. Search 11.x for assert
  5. Other projects
Title Object type File name Summary
DrupalWebTestCase::assertFieldByXPath function modules/simpletest/drupal_web_test_case.php Asserts that a field exists in the current page by the given XPath.
DrupalWebTestCase::assertFieldChecked function modules/simpletest/drupal_web_test_case.php Asserts that a checkbox field in the current page is checked.
DrupalWebTestCase::assertLink function modules/simpletest/drupal_web_test_case.php Pass if a link with the specified label is found, and optional with the
specified index.
DrupalWebTestCase::assertLinkByHref function modules/simpletest/drupal_web_test_case.php Pass if a link containing a given href (part) is found.
DrupalWebTestCase::assertMail function modules/simpletest/drupal_web_test_case.php Asserts that the most recently sent e-mail message has the given value.
DrupalWebTestCase::assertMailPattern function modules/simpletest/drupal_web_test_case.php Asserts that the most recently sent e-mail message has the pattern in it.
DrupalWebTestCase::assertMailString function modules/simpletest/drupal_web_test_case.php Asserts that the most recently sent e-mail message has the string in it.
DrupalWebTestCase::assertNoDuplicateIds function modules/simpletest/drupal_web_test_case.php Asserts that each HTML ID is used for just a single element.
DrupalWebTestCase::assertNoField function modules/simpletest/drupal_web_test_case.php Asserts that a field does not exist with the given name or ID.
DrupalWebTestCase::assertNoFieldById function modules/simpletest/drupal_web_test_case.php Asserts that a field does not exist with the given ID and value.
DrupalWebTestCase::assertNoFieldByName function modules/simpletest/drupal_web_test_case.php Asserts that a field does not exist with the given name and value.
DrupalWebTestCase::assertNoFieldByXPath function modules/simpletest/drupal_web_test_case.php Asserts that a field doesn't exist or its value doesn't match, by XPath.
DrupalWebTestCase::assertNoFieldChecked function modules/simpletest/drupal_web_test_case.php Asserts that a checkbox field in the current page is not checked.
DrupalWebTestCase::assertNoLink function modules/simpletest/drupal_web_test_case.php Pass if a link with the specified label is not found.
DrupalWebTestCase::assertNoLinkByHref function modules/simpletest/drupal_web_test_case.php Pass if a link containing a given href (part) is not found.
DrupalWebTestCase::assertNoOptionSelected function modules/simpletest/drupal_web_test_case.php Asserts that a select option in the current page is not checked.
DrupalWebTestCase::assertNoPattern function modules/simpletest/drupal_web_test_case.php Will trigger a pass if the perl regex pattern is not present in raw content.
DrupalWebTestCase::assertNoRaw function modules/simpletest/drupal_web_test_case.php Pass if the raw text is NOT found on the loaded page, fail otherwise. Raw text
refers to the raw HTML that the page generated.
DrupalWebTestCase::assertNoResponse function modules/simpletest/drupal_web_test_case.php Asserts the page did not return the specified response code.
DrupalWebTestCase::assertNoText function modules/simpletest/drupal_web_test_case.php Pass if the text is NOT found on the text version of the page. The text version
is the equivalent of what a user would see when viewing through a web browser.
In other words the HTML has been filtered out of the contents.
DrupalWebTestCase::assertNoTitle function modules/simpletest/drupal_web_test_case.php Pass if the page title is not the given string.
DrupalWebTestCase::assertNoUniqueText function modules/simpletest/drupal_web_test_case.php Pass if the text is found MORE THAN ONCE on the text version of the page.
DrupalWebTestCase::assertOptionSelected function modules/simpletest/drupal_web_test_case.php Asserts that a select option in the current page is checked.
DrupalWebTestCase::assertPattern function modules/simpletest/drupal_web_test_case.php Will trigger a pass if the Perl regex pattern is found in the raw content.
DrupalWebTestCase::assertRaw function modules/simpletest/drupal_web_test_case.php Pass if the raw text IS found on the loaded page, fail otherwise. Raw text
refers to the raw HTML that the page generated.
DrupalWebTestCase::assertResponse function modules/simpletest/drupal_web_test_case.php Asserts the page responds with the specified response code.
DrupalWebTestCase::assertText function modules/simpletest/drupal_web_test_case.php Pass if the text IS found on the text version of the page. The text version
is the equivalent of what a user would see when viewing through a web browser.
In other words the HTML has been filtered out of the contents.
DrupalWebTestCase::assertTextHelper function modules/simpletest/drupal_web_test_case.php Helper for assertText and assertNoText.
DrupalWebTestCase::assertThemeOutput function modules/simpletest/drupal_web_test_case.php Asserts themed output.
DrupalWebTestCase::assertTitle function modules/simpletest/drupal_web_test_case.php Pass if the page title is the given string.
DrupalWebTestCase::assertUniqueText function modules/simpletest/drupal_web_test_case.php Pass if the text is found ONLY ONCE on the text version of the page.
DrupalWebTestCase::assertUniqueTextHelper function modules/simpletest/drupal_web_test_case.php Helper for assertUniqueText and assertNoUniqueText.
DrupalWebTestCase::assertUrl function modules/simpletest/drupal_web_test_case.php Pass if the internal browser's URL matches the given path.
EnableDisableTestCase::assertSuccessfulDisableAndUninstall function modules/system/system.test Disables and uninstalls a module and asserts that it was done correctly.
EntityCrudHookTestCase::assertHookMessage function modules/simpletest/tests/entity_crud_hook_test.test Pass if the message $text was set by one of the CRUD hooks in
entity_crud_hook_test.module, i.e., if the $text is an element of
$_SESSION['entity_crud_hook_test'].
EntityFieldQueryTestCase::assertEntityFieldQuery function modules/simpletest/tests/entity_query.test Fetches the results of an EntityFieldQuery and compares.
FieldTestCase::assertFieldValues function modules/field/tests/field.test Assert that a field has the expected values in an entity.
FieldUIManageDisplayTestCase::assertNodeViewNoText function modules/field_ui/field_ui.test Asserts that a string is not found in the rendered node in a view mode.
FieldUIManageDisplayTestCase::assertNodeViewText function modules/field_ui/field_ui.test Asserts that a string is found in the rendered node in a view mode.
FieldUIManageDisplayTestCase::assertNodeViewTextHelper function modules/field_ui/field_ui.test Asserts that a string is (not) found in the rendered nodein a view mode.
FieldUIManageFieldsTestCase::assertFieldSettings function modules/field_ui/field_ui.test Asserts field settings are as expected.
FileFieldPathTestCase::assertPathMatch function modules/file/tests/file.test Asserts that a file is uploaded to the right location.
FileFieldTestCase::assertFileEntryExists function modules/file/tests/file.test Asserts that a file exists in the database.
FileFieldTestCase::assertFileEntryNotExists function modules/file/tests/file.test Asserts that a file does not exist in the database.
FileFieldTestCase::assertFileExists function modules/file/tests/file.test Asserts that a file exists physically on disk.
FileFieldTestCase::assertFileIsPermanent function modules/file/tests/file.test Asserts that a file's status is set to permanent in the database.
FileFieldTestCase::assertFileNotExists function modules/file/tests/file.test Asserts that a file does not exist on disk.
FileHookTestCase::assertFileHookCalled function modules/simpletest/tests/file.test Assert that a hook_file_* hook was called a certain number of times.
FileHookTestCase::assertFileHooksCalled function modules/simpletest/tests/file.test Assert that all of the specified hook_file_* hooks were called once, other
values result in failure.
FileTestCase::assertDifferentFile function modules/simpletest/tests/file.test Check that two files are not the same by comparing the fid and filepath.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.