You are here

protected function FeedsMapperTestCase::assertNoNodeFieldValue in Feeds 7.2

Assert that a form field for the given field with the given value does not exist in the current form.

Parameters

$field_name: The name of the field.

$value: The (raw) value of the field.

$index: The index of the field (for q multi-valued field).

See also

FeedsMapperTestCase::getFormFieldsNames()

FeedsMapperTestCase::getFormFieldsValues()

2 calls to FeedsMapperTestCase::assertNoNodeFieldValue()
FeedsMapperFieldTestCase::testClearOutValues in tests/feeds_mapper_field.test
Tests if values are cleared out when an empty value is provided.
FeedsMapperLinkTestCase::testClearOutValues in tests/feeds_mapper_link.test
Tests if values are cleared out when an empty value or no value is provided.

File

tests/feeds_mapper.test, line 77
Contains FeedsMapperTestCase.

Class

FeedsMapperTestCase
Helper class with auxiliary functions for feeds mapper module tests.

Code

protected function assertNoNodeFieldValue($field_name, $value, $index = 0) {
  $names = $this
    ->getFormFieldsNames($field_name, $index);
  $values = $this
    ->getFormFieldsValues($field_name, $value);
  foreach ($names as $k => $name) {
    $value = $values[$k];
    $this
      ->assertNoFieldByName($name, $value, t('Did not find form field %name for %field_name with the value %value.', array(
      '%name' => $name,
      '%field_name' => $field_name,
      '%value' => $value,
    )));
  }
}