protected function DrupalWebTestCase::assertNoFieldByName

7.x drupal_web_test_case.php protected DrupalWebTestCase::assertNoFieldByName($name, $value = '', $message = '')

Asserts that a field does not exist with the given name and value.

Parameters

$name: Name of field to assert.

$value: Value of the field to assert.

$message: Message to display.

$group: The group this message belongs to.

Return value

TRUE on pass, FALSE on fail.

13 calls to DrupalWebTestCase::assertNoFieldByName()
CommentAnonymous::testAnonymous in drupal-7.x/modules/comment/comment.test
Test anonymous comment functionality.
CommentHelperCase::postComment in drupal-7.x/modules/comment/comment.test
Post comment.
FieldFormTestCase::testFieldFormAccess in drupal-7.x/modules/field/tests/field.test
Tests fields with no 'edit' access.
FormValidationTestCase::testValidate in drupal-7.x/modules/simpletest/tests/form.test
Tests form alterations by #element_validate, #validate, and form_set_value().
ForumTestCase::doAdminTests in drupal-7.x/modules/forum/forum.test
Runs admin tests on the admin user.

... See full list

File

drupal-7.x/modules/simpletest/drupal_web_test_case.php, line 3358

Class

DrupalWebTestCase
Test case for typical Drupal tests.

Code

protected function assertNoFieldByName($name, $value = '', $message = '') {
  return $this->assertNoFieldByXPath($this->constructFieldXpath('name', $name), $value, $message ? $message : t('Did not find field by name @name', array('@name' => $name)), t('Browser'));
}