You are here

function autocompleteWidgetsBaseTest::caseTest in Autocomplete Widgets for Text and Number Fields 7

Tests the functionality of the "case sensitive" option.

4 calls to autocompleteWidgetsBaseTest::caseTest()
autocompleteWidgetsAllowedValuesTest::testAllowedValues in tests/autocomplete_widgets.test
autocompleteWidgetsFieldDataTest::testFieldData in tests/autocomplete_widgets.test
autocompleteWidgetsNodeReferenceTest::testNodeTitles in tests/autocomplete_widgets.test
autocompleteWidgetsSuggestedValuesTest::testSuggestedValues in tests/autocomplete_widgets.test

File

tests/autocomplete_widgets.test, line 86

Class

autocompleteWidgetsBaseTest

Code

function caseTest($instance) {
  $settings = $this->settings;
  $settings['autocomplete_case'] = '1';
  $instance['widget']['settings'] = $settings;
  field_update_instance($instance);
  $this
    ->drupalGet($this->path . 'F');
  $this
    ->assertRaw('"FooBar"', 'A case-sensitive suggestion was returned containing the search string.');
  $this
    ->assertNoRaw('"fooBar"', 'Non-matching case-sensitve value was not returned.');
}