You are here

function CountriesBaseSetupTest::assertNoOptionPresent in Countries 7.2

Same name and namespace in other branches
  1. 8 tests/countries.test \CountriesBaseSetupTest::assertNoOptionPresent()
1 call to CountriesBaseSetupTest::assertNoOptionPresent()
CountriesElementUnitTest::testFAPIElement in tests/countries.test

File

tests/countries.test, line 49
Tests for countries.module.

Class

CountriesBaseSetupTest
Test the node_load_multiple() function.

Code

function assertNoOptionPresent($id, $option, $message = NULL) {
  $elements = $this
    ->xpath("//select[@id=:id]//option[@value=:option]", array(
    ':id' => $id,
    ':option' => $option,
  ));
  return $this
    ->assertTrue(empty($elements), $message ? $message : t('Option @option for field @id is not present.', array(
    '@option' => $option,
    '@id' => $id,
  )), t('Browser'));
}